-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aws_launch_configuration userdata issue with aws provider 1.13.0 #4081
Comments
Hey @mukund1989 ! How is # Render a multi-part cloudinit config making use of the part
# above, and other source files
data "template_cloudinit_config" "config" {
gzip = false
base64_encode = false
} |
@catsby This is what my template_cloudinit_config looks like
I also tried with but getting a
|
@catsby I tried using older versions of the aws provider I am kinda stuck, Thanks! |
We are getting |
I get the is this a permanent change or will it be reverted to the previous behaviour? |
@catsby any update on this ? I continue to face the below issue with even TF 0.11.3 & aws provider 1.13
|
I'm experiencing this as well with TF 0.10.7 and aws provider 1.15.0. Even when |
I just received this error as well. I'm running provider.aws: version = "~> 1.25" Was this not merged in or is this something else? I've been able to apply changes all day and it just stopped working after an init. TF version is 0.11.7 |
I found that changing the userdata variable
to
fixes the error. |
I changed the user_data variable to the following but it crashed the EC2 Instance. I am running CoreOS-Stable 1911.4.0. The instance failed Instance Status Checks so I was not able to connect to it.
|
I ran into this same issue. Turned out that the user data template was referring to an empty file. When I replaced
|
For me the problem was that the amount of data being sent as user data was above the threshold. I reduced the size of my scripts and enabled |
I am bumping into this as well and so far have found no alternative to get it to work. Compression is already enabled. |
Marking this issue as stale due to inactivity. This helps our maintainers find and focus on the active issues. If this issue receives no comments in the next 30 days it will automatically be closed. Maintainers can also remove the stale label. If this issue was automatically closed and you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thank you! |
Terraform Version
0.10.6, 0.11.3, 0.11.5
AWS Provider Version
1.13.0
Affected Resource(s)
aws_autoscaling_group
aws_launch_configuration
Terraform Configuration Files
for the launch config
user_data
I have a list of files that is base64 encodedDebug Output
Panic Output
Expected Behavior
A successful plan indicating the below resources to add:
module.masters.aws_launch_configuration.master
id:
associate_public_ip_address: "false"
ebs_block_device.#:
ebs_optimized:
enable_monitoring: "true"
iam_instance_profile: "master-aws-use1-xxxx-xxxx"
image_id: "ami-xxxx"
instance_type: "m4.xlarge"
key_name: "aws-use1-xxxx-xxxx"
name:
name_prefix: "master-aws-use1-xxxx-xxxx"
root_block_device.#: "1"
root_block_device.0.delete_on_termination: "true"
root_block_device.0.iops:
root_block_device.0.volume_size: "20"
root_block_device.0.volume_type: "gp2"
security_groups.#:
user_data: "a529126e049c3263f29b00637cd24eb1775c5d8e"
module.masters.aws_autoscaling_group.masters
id:
arn:
default_cooldown: "6"
desired_capacity: "3"
force_delete: "true"
health_check_grace_period: "3"
health_check_type: "EC2"
launch_configuration: "${aws_launch_configuration.master.name}"
load_balancers.#:
max_size: "3"
metrics_granularity: "1Minute"
min_size: "3"
name: "master-aws-use1-xxxx-xxxx"
protect_from_scale_in: "false"
target_group_arns.#:
vpc_zone_identifier.#: "4"
vpc_zone_identifier.1003057897: "subnet-xxxxxx"
vpc_zone_identifier.2931960226: "subnet-xxxxxx"
vpc_zone_identifier.3016417446: "subnet-xxxxxx"
vpc_zone_identifier.3107657178: "subnet-xxxxxx"
wait_for_capacity_timeout: "10m"
Actual Behavior
Error: Error running plan: 1 error(s) occurred:
module.masters.aws_autoscaling_group.masters: 1 error(s) occurred:
module.masters.aws_autoscaling_group.masters: Resource 'aws_launch_configuration.master' not found for variable 'aws_launch_configuration.master.name'
Steps to Reproduce
terraform plan
on the above resourceImportant Factoids
This error actually relates to hashicorp/terraform#13510
But the root of the problem is that 1.13.0 is erroring out at userdata for launch config.
The same userdata and same code worked fine for
1.11.0
and the only reason I moved to 1.13.0 was to get past the crash as reported in #3962I filed bug #4056 yesterday and I was thrown in a totally different direction because of hashicorp/terraform#13510
The text was updated successfully, but these errors were encountered: