From 2f9a8cd9468fa24c2b981388bf12ec0a5ee4282a Mon Sep 17 00:00:00 2001 From: Anton Babenko Date: Fri, 12 Jan 2024 18:00:20 +0100 Subject: [PATCH] Fixed comparisson with objects/maps --- .pre-commit-config.yaml | 2 +- modules/docker-build/main.tf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e809a4e4..61ef1782 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/antonbabenko/pre-commit-terraform - rev: v1.83.5 + rev: v1.86.0 hooks: - id: terraform_fmt - id: terraform_wrapper_module_for_each diff --git a/modules/docker-build/main.tf b/modules/docker-build/main.tf index 4c82f53e..6ed24831 100644 --- a/modules/docker-build/main.tf +++ b/modules/docker-build/main.tf @@ -29,7 +29,7 @@ resource "docker_registry_image" "this" { keep_remotely = var.keep_remotely - triggers = var.triggers == {} ? { image_id = docker_image.this.image_id } : var.triggers + triggers = length(var.triggers) == 0 ? { image_id = docker_image.this.image_id } : var.triggers } resource "aws_ecr_repository" "this" {