You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please provide a clear and concise description of the issue you are encountering, and a reproduction of your configuration (see the examples/* directory for references that you can copy+paste and tailor to match your configs if you are unable to copy your exact configuration). The reproduction MUST be executable by running terraform init && terraform apply without any further changes.
If your request is for a new feature, please use the Feature request template.
✋ 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
When running terraform apply my expectation is that the list provided for instance_requirements.allowed_instance_types gets populated within the EC2 launch template when it get created.
I expected it to be populated in the same way that it does when using mixed_instances_policy.override. However, when using this method, the allowed_instance_types get added to the autoscaling group instead of the launch template (this is expected).
The launch template is created but the list provided for instance_requirements.allowed_instance_types doesn't get populated into the created launch template.
Terminal Output Screenshot(s)
Additional context
I at the source and found that the problem is due to a missing line of code.
When looking at main.tf:769, I found that allowed_instance_types is utilized within the override block. However, I would expect to find the same logic on main.tf:182, but don't. I have not verified this theory, yet, but adding the following line at main.tf:182 should remedy the issue I'm experiencing:
Description
Please provide a clear and concise description of the issue you are encountering, and a reproduction of your configuration (see the
examples/*
directory for references that you can copy+paste and tailor to match your configs if you are unable to copy your exact configuration). The reproduction MUST be executable by runningterraform init && terraform apply
without any further changes.If your request is for a new feature, please use the
Feature request
template.Before you submit an issue, please perform the following first:
.terraform
directory (! ONLY if state is stored remotely, which hopefully you are following that best practice!):rm -rf .terraform/
terraform init
Versions
Module version [Required]: 7.4.1
Terraform version: v1.8.0
Reproduction Code [Required]
Steps to reproduce the behavior:
Expected behavior
When running
terraform apply
my expectation is that the list provided forinstance_requirements.allowed_instance_types
gets populated within the EC2 launch template when it get created.I expected it to be populated in the same way that it does when using
mixed_instances_policy.override
. However, when using this method, theallowed_instance_types
get added to the autoscaling group instead of the launch template (this is expected).Code like shown here:
Actual behavior
The launch template is created but the list provided for
instance_requirements.allowed_instance_types
doesn't get populated into the created launch template.Terminal Output Screenshot(s)
Additional context
I at the source and found that the problem is due to a missing line of code.
When looking at main.tf:769, I found that
allowed_instance_types
is utilized within theoverride
block. However, I would expect to find the same logic on main.tf:182, but don't. I have not verified this theory, yet, but adding the following line at main.tf:182 should remedy the issue I'm experiencing:The text was updated successfully, but these errors were encountered: