ECHO-565 add audit logging (#358) #240
This file contains hidden or 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: dev-deploy-gitops-backends | |
| on: | |
| push: | |
| branches: | |
| - main | |
| concurrency: | |
| group: dev-deploy-gitops-backends-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| dev-deploy-gitops-backends: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout GitOps Repository | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: dembrane/echo-gitops | |
| token: ${{ secrets.GITOPS_REPO_TOKEN }} | |
| ref: main | |
| - name: Update global.imageTag in values.yaml | |
| id: update_values | |
| run: | | |
| NEW_TAG="${GITHUB_SHA}" | |
| echo "Updating global.imageTag to ${NEW_TAG}" | |
| # Use a regex to update the line that starts with "imageTag:" regardless of its current value. | |
| sed -E -i "s/^( *imageTag: *).*/\1\"${NEW_TAG}\"/" helm/echo/values.yaml | |
| echo "Updated values.yaml content:" | |
| cat helm/echo/values.yaml | |
| - name: Commit and push changes | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions@github.com" | |
| git add helm/echo/values.yaml | |
| git commit -m "Update dev image tag to ${GITHUB_SHA}" | |
| git push origin main |