Skip to content

Commit

Permalink
fix: Ensure that passing values for option group with PostgreSQL does…
Browse files Browse the repository at this point in the history
… not cause errors (#467)

Resolves undefined
  • Loading branch information
bryantbiggs committed Jan 3, 2023
1 parent baf54be commit 696acbb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:

env:
TERRAFORM_DOCS_VERSION: v0.16.0
TFLINT_VERSION: v0.44.1

jobs:
collectInputs:
Expand Down Expand Up @@ -46,6 +47,7 @@ jobs:
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3
with:
terraform-version: ${{ steps.minMax.outputs.minVersion }}
tflint-version: ${{ env.TFLINT_VERSION }}
args: 'terraform_validate --color=always --show-diff-on-failure --files ${{ matrix.directory }}/*'

- name: Pre-commit Terraform ${{ steps.minMax.outputs.minVersion }}
Expand All @@ -54,6 +56,7 @@ jobs:
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3
with:
terraform-version: ${{ steps.minMax.outputs.minVersion }}
tflint-version: ${{ env.TFLINT_VERSION }}
args: 'terraform_validate --color=always --show-diff-on-failure --files $(ls *.tf)'

preCommitMaxVersion:
Expand All @@ -75,5 +78,6 @@ jobs:
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3
with:
terraform-version: ${{ steps.minMax.outputs.maxVersion }}
tflint-version: ${{ env.TFLINT_VERSION }}
terraform-docs-version: ${{ env.TERRAFORM_DOCS_VERSION }}
install-hcledit: true
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ module "db_instance" {
vpc_security_group_ids = var.vpc_security_group_ids
db_subnet_group_name = local.db_subnet_group_name
parameter_group_name = local.parameter_group_name_id
option_group_name = local.option_group
option_group_name = var.engine != "postgres" ? local.option_group : null
network_type = var.network_type

availability_zone = var.availability_zone
Expand Down

0 comments on commit 696acbb

Please sign in to comment.