How to add custom EC2 tags to instances

Hi Team,

Is there a way/configuration to add new tags to the instances created in the elastic-ci setup?
We want to exclude it from our AWS Inspector scanning.


Hello @surajthakur!

Hope you are well - and thanks for the question! :wave:

As of right now, there isn’t a inbuilt parameter within the CI Stack’s CloudFormation template that will add specific tags to EC2 instances that its scaler will spin up. Though of course, if you do want them added to each instance that the stack does create, I’d suggest using something like the aws-cli’s create-tags command that can add them to each instance upon their boot within a bootstrap script (passed through within the stack as BootstrapScriptUrl).

You could always open a PR or raise an Issue on the CI Stack’s repository if you’d like too.

Hope that assists!

Hello @james.s

Thanks for the update on that. I will try to plug in aws-cli tags association command.

Have a good day.

Thanks & Regards

No worries @surajthakur!

Hope that works out for your use case - do let us know if anything else comes to mind. Door always open for a PR/Issue on the GitHub repo in tandem.

Cheers :slightly_smiling_face: