Skip to content

fix: dependabot/46 #235

fix: dependabot/46

fix: dependabot/46 #235

Workflow file for this run

name: dDevKit Components Storybook
on:
workflow_dispatch:
pull_request:
branches:
- 'draft'
- 'main'
push:
branches:
- 'docs'
- 'draft'
- 'main'
paths:
- 'apps/storybook/**'
- 'pnpm-*.yaml'
env:
TEST_EAS_PRIVATE_KEY: ${{ secrets.TEST_EAS_PRIVATE_KEY }}
TEST_USER_PRIVATE_KEY: ${{ secrets.TEST_USER_PRIVATE_KEY }}
LIGHTHOUSE_API_KEY: ${{ secrets.LIGHTHOUSE_API_KEY }}
PASSPORT_API_KEY: ${{ secrets.PASSPORT_API_KEY }}
jobs:
build-storybook:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js and pnpm
uses: ./.github/actions/setup-node-pnpm
- name: Build app
run: pnpm --filter storybook build
- name: Upload storybook build
uses: actions/upload-artifact@v4
with:
name: storybook-build
path: apps/storybook/storybook-static
- name: Install Playwright
run: pnpm dlx playwright install --with-deps
- name: Serve Storybook and run tests
run: |
pnpm dlx concurrently -k -s first -n "SB,TEST" -c "magenta,blue" \
"pnpm dlx http-server apps/storybook/storybook-static --port 6006 --silent" \
"pnpm dlx wait-on tcp:127.0.0.1:6006 && pnpm --filter @geist/storybook test:storybook-runner"
# smoke test, disabled for now
# - name: Build gql
# run: pnpm --filter graphql build:gql
deploy-storybook:
needs: [build-storybook]
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/draft'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js and pnpm
uses: ./.github/actions/setup-node-pnpm
- name: Download storybook build
uses: actions/download-artifact@v4
with:
name: storybook-build
path: apps/storybook/storybook-static
- name: Deploy app
env:
FLEEK_TOKEN: ${{ secrets.FLEEK_TOKEN }}
FLEEK_PROJECT_ID: cm2kkeg090000d5n0pbuh5f9u
run: pnpm --dir apps/storybook deploy:fleek