Manual deploy to prod (from main) #1
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: Manual deploy to prod (from main) | |
on: | |
workflow_dispatch: | |
inputs: | |
skip-tests: | |
description: 'Skip tests?' | |
default: false | |
type: boolean | |
skip-validation: | |
description: 'Skip validation? (eslint, prettier, typecheck)' | |
default: false | |
type: boolean | |
jobs: | |
build: | |
name: Build | |
if: github.ref == 'refs/heads/main' # Only deploy to prod from main branch | |
permissions: | |
contents: read | |
id-token: write | |
uses: navikt/familie-baks-gha-workflows/.github/workflows/build-yarn-app.yaml@main | |
with: | |
build-image: true | |
push-image: true | |
skip-tests: ${{ inputs.skip-tests }} | |
skip-validation: ${{ inputs.skip-validation }} | |
base-path: /barnetrygd/soknad/ | |
secrets: inherit | |
deploy-with-new-image: | |
name: Deploy with new image | |
permissions: | |
id-token: write | |
needs: [ build ] | |
uses: navikt/familie-baks-gha-workflows/.github/workflows/deploy.yaml@main | |
with: | |
image: ${{ needs.build.outputs.image }} | |
cluster: prod-gcp | |
resource: .nais/app-prod.yaml | |
secrets: inherit |