Skip to content

Deploy

Deploy #29

Workflow file for this run

name: Deploy
on:
workflow_dispatch:
inputs:
artifact_id:
description: The ID of the source artifact
required: true
type: string
run_id:
description: The ID of the run containing the source artifact
required: true
type: string
jobs:
prepare:
runs-on: ubuntu-latest
steps:
- uses: actions/create-github-app-token@67018539274d69449ef7c02e8e71183d1719ab42 # v2.1.4
id: auth
with:
app-id: ${{ secrets.APP_ID }}
owner: ${{ secrets.PAGES_SOURCE_REPO_OWNER }}
private-key: ${{ secrets.APP_PRIVATE_KEY }}
repositories: ${{ secrets.PAGES_SOURCE_REPO_NAME }}
- uses: actions/download-artifact@634f93cb2916e3fdff6788551b99b062d0335ce0 # v5.0.0
with:
artifact-ids: ${{ inputs.artifact_id }}
github-token: ${{ steps.auth.outputs.token }}
path: _site/
repository: ${{ secrets.PAGES_SOURCE_REPO_OWNER }}${{ '/' }}${{ secrets.PAGES_SOURCE_REPO_NAME }}
run-id: ${{ inputs.run_id }}
- uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
needs: prepare
permissions:
id-token: write
pages: write
runs-on: ubuntu-latest
steps:
- uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4.0.5
id: deployment