Skip to content

CD

CD #134

Workflow file for this run

name: CD
on:
push:
branches:
- main
schedule:
- cron: '0 1 * * *' # runs daily at 01:00 UTC
permissions:
contents: read
pages: write
id-token: write
env:
GITHUB_PAGES_DEPLOY: ${{ github.ref == 'refs/heads/main' && (github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') }}
jobs:
initial:
runs-on: ubuntu-latest
outputs:
GITHUB_PAGES_DEPLOY: ${{ env.GITHUB_PAGES_DEPLOY }}
defaults:
run:
shell: pwsh
steps:
- name: Dump Env
run: |
Write-Output @'
${{ toJSON(env) }}
'@
- name: Dump GitHub
run: |
Write-Output @'
${{ toJSON(github) }}
'@
- name: Dump Inputs
run: |
Write-Output @'
${{ toJSON(inputs) }}
'@
ci:
needs: initial
uses: ./.github/workflows/ci.yaml
with:
upload-artifact: ${{ needs.initial.outputs.GITHUB_PAGES_DEPLOY == 'true' }}
cd:
needs: [initial, ci]
if: needs.initial.outputs.GITHUB_PAGES_DEPLOY == 'true'
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
concurrency:
group: github-pages
cancel-in-progress: false
runs-on: ubuntu-latest
steps:
- id: deployment
uses: actions/deploy-pages@main