Skip to content

Merge pull request #169 from osg-htc/xalim-dagman-links #335

Merge pull request #169 from osg-htc/xalim-dagman-links

Merge pull request #169 from osg-htc/xalim-dagman-links #335

Workflow file for this run

name: Deploy self
on:
push:
branches:
- main
jobs:
Run-Build-Scripts:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: 'recursive'
fetch-depth: 0
- uses: actions/setup-python@v4
with:
python-version: '3.x' # Version range or exact version of a Python version to use, using SemVer's version range syntax
architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified
- run: |
pip3 install -r scripts/requirements.txt
python scripts/link-docs.py
- name: Pull down submodules
run: |
if [ -n "$(git status --porcelain)" ]; then
git config user.name "GitHub Actions"
git config user.email "[email protected]"
git add .
git commit -m "Link Files"
git push --set-upstream origin main
else
echo "no changes";
fi
Trigger-New-Documentation-Release:
runs-on: ubuntu-latest
if: startsWith(github.repository, 'osg-htc/')
needs: Run-Build-Scripts
env:
OWNER: osg-htc
OSG_REPO: osg-portal-documentation
PATH_REPO: path-portal-documentation
WORKFLOW_ID: update-documentation.yml
steps:
- name: Trigger Documentation Release
run: |
# Toggle OSG Portal Documentation Site
curl -X POST -H "Accept: application/vnd.github+json" -H "Authorization: Bearer ${{ secrets.REPO_ACCESS_TOKEN }}" https://api.github.com/repos/${{env.OWNER}}/${{env.OSG_REPO}}/actions/workflows/${{env.WORKFLOW_ID}}/dispatches -d '{"ref":"master"}'
# Toggle PATh Portal Documentation Site
curl -X POST -H "Accept: application/vnd.github+json" -H "Authorization: Bearer ${{ secrets.REPO_ACCESS_TOKEN }}" https://api.github.com/repos/${{env.OWNER}}/${{env.PATH_REPO}}/actions/workflows/${{env.WORKFLOW_ID}}/dispatches -d '{"ref":"main"}'