Skip to content

Merge pull request #605 from woowacourse-teams/fix/265-home-page-fix-… #47

Merge pull request #605 from woowacourse-teams/fix/265-home-page-fix-…

Merge pull request #605 from woowacourse-teams/fix/265-home-page-fix-… #47

name: Client Deploy Storybook
on:
push:
branches: [dev]
paths: client/**
workflow_dispatch:
jobs:
deploy:
defaults:
run:
working-directory: client
runs-on: ubuntu-latest
permissions:
contents: write
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true
steps:
- name: Use repository source
uses: actions/checkout@v3
- name: Use node.js
uses: actions/setup-node@v3
with:
node-version: 18
- name: Cache node_modules
id: cache
uses: actions/cache@v3
with:
path: '**/node_modules'
key: ${{ runner.os }}-node-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile
- name: Build storybook
run: yarn build:storybook
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./client/storybook-static
destination_dir: storybook