install-aws-server: Configurable IAM profile for hosts.

This commit is contained in:
Alex Vandiver 2022-01-12 21:23:42 +00:00 committed by Tim Abbott
parent d9d3368553
commit c66fd6a01a
1 changed files with 2 additions and 1 deletions

View File

@ -54,6 +54,7 @@ AWS_ZONE_ID=$(lookup zone_id)
SECURITY_GROUPS=$(lookup security_groups)
AMI_ID=$(lookup image_id)
INSTANCE_TYPE=$(lookup instance_type)
IAM_PROFILE=$(lookup iam_profile)
SSH_SECRET_ID=$(lookup ssh_secret_id)
# Verify it doesn't exist already
@ -69,7 +70,7 @@ if [ "$EXISTING_RECORDS" != "0" ]; then
fi
EXTRA_ARGS+=(
--iam-instance-profile "Name=\"EC2ProdInstance\""
--iam-instance-profile "Name=\"$IAM_PROFILE\""
--image-id "$AMI_ID"
--instance-type "$INSTANCE_TYPE"
--security-group-ids "$SECURITY_GROUPS"