Creating a Role for an EC2 Instance with CloudFormation

ACM.107 Using an IAM Role Profile with an EC2 Instance for short-term rotating credentials

Teri Radichel
Cloud Security

--

Part of my series on Automating Cybersecurity Metrics. IAM. The Code.

Free Content on Jobs in Cybersecurity | Sign up for the Email List

In the last post we created a VPC endpoint for CloudFormation so we can access the AWS service from a private network. The post also showed you when you might not actually be using a private network when you have a VPC Endpoint configured.

In this post we want to test our VPC endpoint, but before we can do that we need some credentials on the VM that we want to use to test CloudFormation.

We’re going to create a role in this post that we can assign to this instance to perform CloudFormation actions. We’re going to use our AppDeploy role and modify it so it can be assigned to an EC2 instance.

This role will look similar to other roles we created with one exception. To enable the ability to associate this role with an EC2 instance we need to create an instance profile.

--

--

Teri Radichel
Cloud Security

CEO 2nd Sight Lab | Penetration Testing & Assessments | AWS Hero | Masters of Infosec & Software Engineering | GSE 240 etc | IANS | SANS Difference Makers Award