fix: yandex metrika #26
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 to prod | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| deploy_site: | |
| name: 🚀 Deploy to prod | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: website | |
| steps: | |
| - name: 🔃 Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: ⚙️ Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: '22' | |
| - name: ⚙️ Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| - name: ⚙️ Install dependencies | |
| run: bun install | |
| - name: 🛠️ Build site | |
| env: | |
| NODE_ENV: production | |
| CONTEXT: production | |
| ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }} | |
| run: bun run build | |
| - name: 🔼 Upload site | |
| run: | | |
| AWS_ACCESS_KEY_ID=${{ secrets.ACCESS_KEY_ID }} \ | |
| AWS_SECRET_ACCESS_KEY=${{ secrets.SECRET_ACCESS_KEY }} \ | |
| aws s3 sync "build/" "s3://docs-getdbt-tech-site/" \ | |
| --endpoint-url https://storage.yandexcloud.net \ | |
| --delete --only-show-errors --no-progress | |
| shell: bash | |
| - name: 🔃 Purge CDN cache | |
| uses: yc-actions/yc-cdn-cache@v1 | |
| with: | |
| yc-sa-json-credentials: ${{ secrets.YC_SA_JSON_CREDENTIALS }} | |
| cdn-resource-id: bc8abm2727b4b5law2ep | |
| - name: 🏁 Create GitHub deployment | |
| uses: chrnorm/deployment-action@v2 | |
| with: | |
| token: '${{ github.token }}' | |
| initial-status: success | |
| environment-url: https://docs.getdbt.tech/ | |
| environment: prod |