Skip to content

Commit

Permalink
Template infra deploy #9811765241
Browse files Browse the repository at this point in the history
  • Loading branch information
nava-platform-bot committed Jul 5, 2024
1 parent 86eb209 commit 6ca0e3c
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 3 deletions.
17 changes: 17 additions & 0 deletions .github/actions/setup-terraform/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: 'Set up Terraform'
description: 'Set up Terraform with the version stored in the .terraform-version file'
runs:
using: "composite"
steps:
- name: Get .terraform-version
id: get-terraform-version
run: |
terraform_version="$(cat .terraform-version)"
echo "Terraform version: ${terraform_version}"
echo "terraform_version=${terraform_version}" >> "$GITHUB_OUTPUT"
shell: bash
- name: Set up Terraform
uses: hashicorp/setup-terraform@v2
with:
terraform_version: ${{ steps.get-terraform-version.outputs.terraform_version }}
terraform_wrapper: false
4 changes: 2 additions & 2 deletions .github/workflows/build-and-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@ jobs:
echo "is_image_published=$is_image_published" >> "$GITHUB_OUTPUT"
- name: Build release
if: steps.check-image-published.outputs.IS_IMAGE_PUBLISHED == 'false'
if: steps.check-image-published.outputs.is_image_published == 'false'
run: make APP_NAME=${{ inputs.app_name }} release-build

- name: Publish release
if: steps.check-image-published.outputs.IS_IMAGE_PUBLISHED == 'false'
if: steps.check-image-published.outputs.is_image_published == 'false'
run: make APP_NAME=${{ inputs.app_name }} release-publish
3 changes: 3 additions & 0 deletions .github/workflows/database-migrations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: Set up Terraform
uses: ./.github/actions/setup-terraform

- name: Configure AWS credentials
uses: ./.github/actions/configure-aws-credentials
with:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: Set up Terraform
uses: ./.github/actions/setup-terraform

- name: Configure AWS credentials
uses: ./.github/actions/configure-aws-credentials
with:
Expand Down
2 changes: 1 addition & 1 deletion .template-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
dab74fdbad679ed48657a2751f733353aff7ac23
789a063ad88512edc2ac2ec971d67d1ea62ebfe5

0 comments on commit 6ca0e3c

Please sign in to comment.