redStack provisions EC2 instances, VPCs, subnets, security groups, Elastic IPs, network interfaces, VPC peering connections, and route tables. Your AWS credentials need enough permissions to create and destroy all of these resources. There are two options. Choose based on the type of AWS account you are using.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/BaddKharma/redStack/llms.txt
Use this file to discover all available pages before exploring further.
Option A: AdministratorAccess
Recommended for dedicated lab accounts. If you created a separate AWS account solely for this lab,AdministratorAccess is the right choice. There are no other workloads, billing resources, or sensitive data in the account to protect. Admin access on an empty account carries the same real-world risk as a scoped policy: if the credentials are compromised, the attacker can only reach the lab infrastructure you already plan to tear down.
Least privilege adds meaningful protection when credentials could expose things beyond this lab. On a dedicated account, there is nothing else to expose. Use Option A and save the complexity of Option B for when it actually buys you something.
Create the IAM user
Open the IAM Console and navigate to Users → Create user.Set the username to
redS-operator (or any name you prefer).Attach AdministratorAccess
On the Set permissions screen, choose Attach policies directly.Search for
AdministratorAccess and check the box next to it.Click Next, then Create user.Generate an access key
Open the newly created user and go to the Security credentials tab.Click Create access key.Select Command Line Interface (CLI), acknowledge the recommendation, then click Next.Copy the Access Key ID and Secret Access Key. The secret is shown only once — save it now.
Configure the AWS CLI
Run
aws configure from inside your redStack/ directory and enter the values from the previous step:| Prompt | Value |
|---|---|
| AWS Access Key ID | The access key ID you just copied |
| AWS Secret Access Key | The secret access key you just copied |
| Default region name | us-east-1 (or your chosen region — must match aws_region in terraform.tfvars) |
| Default output format | json |
Option B: Least-privilege policy
Only required if you are deploying into a shared or production AWS account. Use this option if the AWS account running redStack also contains other workloads, active resources, or anything you cannot afford to lose or expose. Scoping the credentials to only what redStack needs limits the blast radius if the access key is ever leaked or misused.Why each permission is needed
Why each permission is needed
ec2:*— redStack is EC2-only infrastructure. Every resource Terraform creates and destroys (instances, VPCs, subnets, security groups, ENIs, EIPs, VPC peering, route tables) maps to an EC2 API call. No S3, RDS, Lambda, or other services are used.sts:GetCallerIdentity— Terraform calls this atinitto verify credentials and identify the account. Without it,terraform initfails before any resources are touched.iam:GetUser,iam:GetUserPolicy,iam:ListUserPolicies,iam:ListAttachedUserPolicies— Read-only, self-scoped to${aws:username}. Lets you inspect your own permissions when debugging an access denied error. No IAM write access is granted and the scope prevents reading any other principal’s policies.
Minimum IAM policy
Create the IAM user
Open the IAM Console and navigate to Users → Create user.Set the username to
redS-operator.Create the least-privilege policy
On the Set permissions screen, choose Attach policies directly, then click Create policy.Select the JSON tab and paste the policy above.Name the policy
redStack-least-privilege, then click Create policy.Attach the policy to the user
Return to the user creation screen. Search for
redStack-least-privilege and check the box next to it.Click Next, then Create user.Generate an access key
Open the newly created user and go to the Security credentials tab.Click Create access key.Select Command Line Interface (CLI), acknowledge the recommendation, then click Next.Copy the Access Key ID and Secret Access Key. The secret is shown only once.
Verify credentials
After runningaws configure, confirm the credentials work:
aws configure and that the IAM user has not been deactivated.
aws configure writes credentials to ~/.aws/credentials and region/output preferences to ~/.aws/config. Terraform reads these files automatically when it initializes. You only need to run aws configure once per machine.