Skip to content

Commit

Permalink
Only add quotations in dev
Browse files Browse the repository at this point in the history
not for staging and prod
  • Loading branch information
tsundvoll committed Mar 11, 2024
1 parent 1e4f0e2 commit d296979
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/deploy_to_development.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ jobs:
Environment: development
Registry: ghcr.io
ImageName: ${{ github.repository }}
Tag: ${{ needs.get-short-sha.outputs.tag }}
# Add quotation marks for the tags used in dev environment,
# due to the commit hash can be interpreted as an integer if only numbers
Tag: '${{ needs.get-short-sha.outputs.tag }}'
AuthorEmail: ${{ github.event.head_commit.author.email }}
AuthorName: ${{ github.event.head_commit.author.name }}
secrets:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/update_aurora_deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,19 +44,19 @@ jobs:
run: |
COMPONENT=frontend
TAG_LINE_NUMBER=$(($(grep -n "${{ inputs.Registry }}/${{ inputs.ImageName }}-${COMPONENT}" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml | cut --delimiter=":" --fields=1)+1))
sed -i "${TAG_LINE_NUMBER} s/newTag:.*/newTag: '${{ inputs.Tag }}'/" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml
sed -i "${TAG_LINE_NUMBER} s/newTag:.*/newTag: ${{ inputs.Tag }}/" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml
- name: Update backend in file
run: |
COMPONENT=backend
TAG_LINE_NUMBER=$(($(grep -n "${{ inputs.Registry }}/${{ inputs.ImageName }}-${COMPONENT}" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml | cut --delimiter=":" --fields=1)+1))
sed -i "${TAG_LINE_NUMBER} s/newTag:.*/newTag: '${{ inputs.Tag }}'/" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml
sed -i "${TAG_LINE_NUMBER} s/newTag:.*/newTag: ${{ inputs.Tag }}/" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml
- name: Update broker in file
run: |
COMPONENT=broker
TAG_LINE_NUMBER=$(($(grep -n "${{ inputs.Registry }}/${{ inputs.ImageName }}-${COMPONENT}" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml | cut --delimiter=":" --fields=1)+1))
sed -i "${TAG_LINE_NUMBER} s/newTag:.*/newTag: '${{ inputs.Tag }}'/" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml
sed -i "${TAG_LINE_NUMBER} s/newTag:.*/newTag: ${{ inputs.Tag }}/" k8s_kustomize/overlays/${{ inputs.Environment }}/kustomization.yaml
- name: Update infrastructure in GitHub
run: |
Expand Down

0 comments on commit d296979

Please sign in to comment.