Bug Report - Copy Launch configuration to launch template


Proceed as follows: step 1: go to Launch configurations console. step 2: choose a Launch configuration. step 3: copy to launch template > Copy selected > Copy.

I got an error message: "The security group ID 'awseb-e-yy32fjb***-stack-AWSEBSecurityGroup-RKGBZ9JQ****' is not valid. The expected format is sg-xxxxxxxx or sg-xxxxxxxxxxxxxxxxx."

After investigating, I realized that AWS is taking "Security name" data instead of "Security ID" when copying Launch configuration to launch template.

as in my case above, 'awseb-e-yy32fjbzmp-stack-AWSEBSecurityGroup-RKGBZ9JQ****' is the security group name, AWS sends this data as security group ID, so get above error.

3 Answers

Thanks for reporting this, and for the followup info in the comment. I'll look into the Security group name vs ID issue with our console team. However, I see your resources have AWSEB in the name. This implies the resources are created through ElasticBeanstalk. You shouldn't update the ASG directly, as any update to the Beanstalk environment in the future will likely undo your changes. Instead, update the Beanstalk environment directly to migrate it to a launch template.

If you think any changes may have been made to the instance/application/ASG outside of Beanstalk, I would highly encourage taking a snapshot or otherwise backing up anything important first to prevent accidental data loss, since Beanstalk will redeploy the last known application revision when you update it.

answered a year ago

The guidance on converting launch configs to templates isn't very clear when it comes to Elastic Beanstalk, having now done this I've found that a normal environment update or environment clone, doesn't swap the configurations to templates, however enabling spot instances under "Capacity -> Auto Scaling Group -> Fleet Composition = Combine purchase options and instances" does then force the environment to convert them to templates as expected.

answered a year ago

I just tried the same and it worked fine for me in ap-southeast-2.

answered a year ago
  • i just tried again, when i create a new Launch configuration everything works fine. it seems that this error only occurs with old Launch configurations (created around 2016 - 2017).

    when I try to create a Launch template by myself, based on the old Launch configuration configs, I can't find the AMI that Launch configuration is using.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions