A small GitHub Action composite which can update a resource attribute in HCL in another repository.
See action.yml
Basic Infrastructure example:
steps:
- uses: joelrose/[email protected]
with:
gh-token: ${{ secrets.GH_TOKEN }}
variable: "variable.image_hash.default"
value: ${{ GITHUB_SHA }}
repository: "github.com/joelrose/infrastructure"
file-path: "variables.tf"
git-commit-message: "automated: deploy xxx service"
git-branch-name: "automated/${GITHUB_SHA}"