Skip to content

Commit

Permalink
Merge pull request #2968 from statisticsnorway/MIM-2005-proper-nais-t…
Browse files Browse the repository at this point in the history
…tl-changes

[MIM-2005] nais delete - Use same image as the orignal PR
  • Loading branch information
Carl-OW authored Oct 18, 2024
2 parents e411fbb + 701e052 commit a8b0f4f
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/delete_nais.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ jobs:
env:
REGISTRY: europe-north1-docker.pkg.dev/nais-management-b3a7/ssbno/ssbno-mimir
IMAGE: mimir
TAG: ${{ github.head_ref }}-${{ github.sha }}
steps:
# Checkout the PR branch (e.g., MIM-2005-nais-deploy-test-6)
- name: Checkout the PR branch
Expand Down Expand Up @@ -57,11 +56,17 @@ jobs:
run: |
sed -i 's/ttl: .*/ttl: "10m"/' nais.yaml
# Use the previously built image by reusing the tag from the initial deployment
- name: Retrieve the original image tag
run: |
echo "Retrieving original image tag"
echo "IMAGE_TAG=${{ github.sha }}" >> $GITHUB_ENV
# Redeploy the application with the modified TTL and correct image and branch variables
- uses: nais/deploy/actions/deploy@v2
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
CLUSTER: test
RESOURCE: nais.yaml
VAR: image=${{ env.REGISTRY }}/${{ env.IMAGE }}:${{ env.TAG }},branch=${{ env.ISSUE_NUMBER }}
VAR: image=${{ env.REGISTRY }}/${{ env.IMAGE }}:${{ env.IMAGE_TAG }},branch=${{ env.ISSUE_NUMBER }}
DEPLOY_SERVER: deploy.ssb.cloud.nais.io:443

0 comments on commit a8b0f4f

Please sign in to comment.