chore: kustomize deploy #125
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 staging | |
on: | |
pull_request: | |
types: [ready_for_review, opened, reopened, synchronize] | |
branches: | |
- main | |
jobs: | |
test: | |
name: Run tests when pull request is created | |
if: github.event.pull_request.draft == false | |
uses: Informasjonsforvaltning/workflows/.github/workflows/test-rust.yaml@main | |
with: | |
toolchain_tc: nightly-2024-11-01 | |
secrets: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
build: | |
name: Build with reusable workflow when pull request is created | |
if: github.event.pull_request.draft == false | |
uses: Informasjonsforvaltning/workflows/.github/workflows/build-push.yaml@main | |
with: | |
app_name: fdk-mqa-assmentator | |
environment: staging | |
secrets: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
deploy: | |
name: Deploy to staging environment with reusable workflow when test and build is successful | |
if: ${{ github.actor != 'dependabot[bot]' && github.event.pull_request.draft == false }} | |
needs: [test, build] | |
uses: Informasjonsforvaltning/workflows/.github/workflows/deploy.yaml@main | |
with: | |
app_name: fdk-mqa-assmentator | |
environment: staging | |
cluster: digdir-fdk-dev | |
secrets: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
DIGDIR_FDK_AUTODEPLOY: ${{ secrets.DIGDIR_FDK_DEV_AUTODEPLOY }} | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} |