Skip to content

Commit

Permalink
Refactor GitHub Pages deployment workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
talk2MeGooseman authored Mar 13, 2024
1 parent d222d5c commit e87ecc3
Showing 1 changed file with 21 additions and 15 deletions.
36 changes: 21 additions & 15 deletions .github/workflows/manual-storybook-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,8 @@ name: Publish Storybook GitHub Page

on: workflow_dispatch


jobs:
storybook:
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
pages: write # to deploy to Pages
id-token: write # to verify the deployment originates from an appropriate source

# Deploy to the github-pages environment
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

build:
# Specify runner + deployment step
runs-on: ubuntu-latest

Expand All @@ -38,7 +27,24 @@ jobs:
with:
path: '.out/'

- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
storybook-to-pages:
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
contents: read
pages: write
id-token: write

# Deploy to the github-pages environment
environment:
name: gh-pages
url: ${{ steps.deployment.outputs.page_url }}

needs: build
runs-on: ubuntu-latest
name: Deploy
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
with:
artifact_name: 'gh-pages'

0 comments on commit e87ecc3

Please sign in to comment.