Merge pull request #193 from navikt/feature/nais-docker-push #5
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: Build, push, and deploy (preprod) | |
on: | |
push: | |
branches: | |
- 'main' | |
paths-ignore: | |
- '**.md' | |
- '**/**.md' | |
jobs: | |
build-and-test: | |
name: Test frontend | |
uses: ./.github/workflows/test.yml | |
build-and-push: | |
name: Build and push Docker container for preprod | |
uses: ./.github/workflows/build-push.yml | |
with: | |
environment: preprod | |
secrets: inherit | |
deploy-preprod: | |
name: Deploy to preprod | |
needs: [build-and-test, build-and-push] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: nais/deploy/actions/deploy@v1 | |
env: | |
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }} | |
DRY_RUN: false | |
PRINT_PAYLOAD: true | |
CLUSTER: dev-gcp | |
RESOURCE: .nais/nais-preprod.yml | |
VAR: app_version=${{ github.sha }},image=${{ needs.build-and-push.outputs.image }} | |