Skip to content

Production Deployment #189

Production Deployment

Production Deployment #189

Workflow file for this run

name: prod
run-name: Production Deployment
on:
push:
branches: [main]
jobs:
# Ensure a successful deploy to staging before deploying to prod
deploy-stage:
uses: ./.github/workflows/stage.yaml
secrets: inherit
release:
runs-on: ubuntu-latest
needs: deploy-stage
environment: prod
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- run: ./bin/make release
env:
GITHUB_APP_ID: ${{ secrets.EVYLANGBOT_GITHUB_APP_ID }}
GITHUB_APP_PEM: ${{ secrets.EVYLANGBOT_GITHUB_APP_PEM }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
deploy-prod:
runs-on: ubuntu-latest
needs: release
environment: prod
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- run: ./bin/make deploy ENV=prod CHANNEL=live
env:
FIREBASE_SERVICE_ACCOUNT: ${{ secrets.FIREBASE_SERVICE_ACCOUNT_EVY_LANG }}
- run: ./bin/make e2e USE_DOCKER=1
env:
BASEURL: ${{ env.BASEURL_APEX }}
BASEURL_PLAY: ${{ env.BASEURL_PLAY }}
BASEURL_DOCS: ${{ env.BASEURL_DOCS }}
howl-on-fail:
runs-on: ubuntu-latest
needs: [deploy-stage, release, deploy-prod]
if: always() && contains(join(needs.*.result, ','), 'failure')
steps:
- uses: actions/checkout@v4
- run: ./bin/howl
env:
# Notify evy Discord server on channel #evydev
DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}
DISCORD_TEXT: "@here"