diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..5414286 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,38 @@ +name: Release + +on: + push: + branches: + - release/* + release: + types: [published] + +jobs: + deploy: + runs-on: 'ubuntu-latest' + environment: github-pages + env: + VITE_HONEYBADGER_API_KEY: ${{ secrets.HONEYBADGER_API_KEY }} + VITE_POSTHOG_API_KEY: ${{ secrets.POSTHOG_API_KEY }} + VITE_AUTH_TENANT_URL: ${{ secrets.AUTH_TENANT_URL }} + + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 16 + cache: "yarn" + - run: yarn + - run: yarn predeploy + - uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./dist + keep_files: true + destination_dir: latest + - uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./dist + keep_files: true + destination_dir: ${{ github.ref }} \ No newline at end of file