Bug with `docker-build` module on latest tag and commti.
shymega opened this issue · 4 comments
Description
I've been trying to use this module with private code, and I get an error about an Unsupported block type
, the block type being build
.
This is reproducible with the /examples/container-image
Terraform configuration on the latest mainline.
I haven't been able to find a cause yet, but I think there's been a breakage with the latest changes.
-
✋ I have searched the open/closed issues and my issue is not listed.
⚠️ Note
Before you submit an issue, please perform the following first:
- Remove the local
.terraform
directory (! ONLY if state is stored remotely, which hopefully you are following that best practice!):rm -rf .terraform/
- Re-initialize the project root to pull down modules:
terraform init
- Re-attempt your terraform plan or apply and check if the issue still persists
Versions
- Module version [Required]: v4.7.2
- Terraform version:
Terraform v1.3.7
- Provider version(s):
Terraform v1.3.7
on linux_amd64
+ provider registry.terraform.io/hashicorp/aws v4.50.0
+ provider registry.terraform.io/hashicorp/external v2.2.3
+ provider registry.terraform.io/hashicorp/local v2.3.0
+ provider registry.terraform.io/hashicorp/null v3.2.1
+ provider registry.terraform.io/hashicorp/random v3.4.3
+ provider registry.terraform.io/kreuzwerker/docker v3.0.1
Reproduction Code [Required]
$ terraform init && terraform apply
Steps to reproduce the behavior:
Clone this repo, change the directory to /examples/container-image
, and run the commands above. This happens on mainline, and on the latest release.
Expected behavior
A valid Terraform application process, with no errors.
Actual behavior
Receiving the following error:
│ Error: Unsupported block type
│
│ on ../../modules/docker-build/main.tf line 15, in resource "docker_registry_image" "this":
│ 15: build {
│
│ Blocks of type "build" are not expected here.
Terminal Output Screenshot(s)
Additional context
I have also ran into this issue, and the workaround I've found is to set the kreuzwerker/docker
version to ~> 2.12
. It seems that the 3.0
release broke this downstream module.
This issue has been resolved in version 4.8.0