Skip to content

Deploy

Deploy #6

name: Deploy
on:
workflow_run:
branches: [ "main" ]
workflows: [ "CI" ]
types: [ completed ]
workflow_dispatch:
concurrency:
group: "gh-pages"
cancel-in-progress: true
permissions:
contents: read
pages: write
id-token: write
jobs:
deploy-pages:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Download Artifact
uses: actions/download-artifact@v4
with:
name: dist
path: ./dist/
run-id: ${{ github.event.workflow_run.id }}
github-token: ${{ github.token }}
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload Pages Artifact
uses: actions/upload-pages-artifact@v3
with:
path: './dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4