design-library v3.0.19 #95
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Deploy production Storybook | |
| on: | |
| workflow_dispatch: | |
| release: | |
| types: [published] | |
| jobs: | |
| build_and_deploy: | |
| if: contains(github.event.release.name, 'design-library') && !contains(github.event.release.name, 'beta') | |
| runs-on: ubuntu-latest | |
| name: Build and Deploy | |
| environment: | |
| name: production-storybook | |
| url: https://design-library.developer.bcc.no | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v2 | |
| with: | |
| version: 9 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v3 | |
| with: | |
| node-version-file: design-library/.node-version | |
| registry-url: "https://registry.npmjs.org" | |
| cache: "pnpm" | |
| cache-dependency-path: design-library/pnpm-lock.yaml | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| working-directory: design-library | |
| - name: Build Storybook | |
| run: pnpm build-storybook | |
| working-directory: design-library | |
| - name: Deploy | |
| id: builddeploy | |
| uses: Azure/static-web-apps-deploy@v1 | |
| with: | |
| azure_static_web_apps_api_token: ${{ secrets.AZURE_DEPLOY_TOKEN }} | |
| action: "upload" | |
| app_location: "design-library/storybook-static" | |
| skip_app_build: true | |
| skip_api_build: true |