Deploy to prod #17
Workflow file for this run
This file contains 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: | |
release: | |
types: | |
- published | |
concurrency: | |
# Ensures that only one workflow task will run at a time. Previous builds, if | |
# already in process, will get cancelled. Only the latest commit will be allowed | |
# to run, cancelling any workflows in between | |
group: ${{ github.workflow }}-${{ github.job }}-${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
uses: ./.github/workflows/sub-build-push-image.yml | |
with: | |
environment: production | |
dockerfile_path: ./Dockerfile | |
dockerfile_target: runner | |
app_name: ${{ vars.APP_NAME }} | |
registry: ${{ vars.GOOGLE_ARTIFACT_REGISTRY }} | |
secrets: inherit | |
deploy: | |
needs: [build] | |
uses: ./.github/workflows/sub-cloudrun-deploy.yml | |
with: | |
environment: production | |
project_id: ${{ vars.GOOGLE_PROJECT_ID }} | |
region: ${{ vars.GOOGLE_CLOUD_REGION }} | |
app_name: ${{ vars.APP_NAME }} | |
image_digest: ${{ needs.build.outputs.image_digest }} | |
min_instances: '1' | |
max_instances: '300' | |
cpu: '2' | |
memory: 1Gi | |
secrets: inherit |