Skip to content

Instantly share code, notes, and snippets.

@leepa
Created March 11, 2020 15:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save leepa/5d18b9f55cc762bf9100b8f5dc9dd869 to your computer and use it in GitHub Desktop.
Save leepa/5d18b9f55cc762bf9100b8f5dc9dd869 to your computer and use it in GitHub Desktop.
const cluster = new bottle.BottlerocketCluster(this, 'Cluster');
const ami = ssm.StringParameter.valueForStringParameter(this, '/aws/service/bottlerocket/aws-k8s-1.15/x86_64/latest/image_id');
cluster.node.findAll().forEach(s => {
if (s instanceof asg.CfnLaunchConfiguration) {
const asg = s as asg.CfnLaunchConfiguration;
asg.imageId = ami;
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment