I'm trying to disable IMDSv1 in an ElasticBeanstalk Module I'm writing. I'm looking at the available EB auto scaling setting options here. It shows that the DisableIMDSv1 is a valid setting but when I run a terraform apply it's giving me this error.
ConfigurationValidationException: Configuration validation exception: Invalid option specification (Namespace: 'aws:autoscaling:launchconfiguration', OptionName: 'DisableIMDSv1'): Unknown configuration setting.
status code: 400
I'm using a variable to loop through my settings so this is what the variable code with the DisableIMDSv1 looks like.
launch_configuration = {
namespace = "aws:autoscaling:launchconfiguration"
name = "IamInstanceProfile"
value = "some-role"
}
disable_imds_v1 = {
namespace = "aws:autoscaling:launchconfiguration"
name = "DisableIMDSv1"
value = "true"
}
If I comment out the disable_imds_v1 part I can successfully run my terraform apply.
It looks like the DisableIMDSv1 option might be a new addition to the available beanstalk settings options. Added June 2020.
Is this a terraform issue where they don't have the option available or I need to upgrade to terraform 0.13.x? I'm using terraform version 0.12.23 with aws provider 3.2.0. I ran a terraform init -upgrade which bumped up my aws provider from 3.1.0 to 3.2.0 thinking that might fix it but I'm still seeing the Unknown configuration setting message.