Terraform resource: aws iam instance profile
(Redirected from Aws iam instance profile)
Jump to navigation
Jump to search
Official example[edit]
resource "aws_iam_instance_profile" "test_profile" { name = "test_profile" role = aws_iam_role.role.name } data "aws_iam_policy_document" "assume_role" { statement { effect = "Allow" principals { type = "Service" identifiers = ["ec2.amazonaws.com"] } actions = ["sts:AssumeRole"] } } resource "aws_iam_role" "role" { name = "test_role" path = "/" assume_role_policy = data.aws_iam_policy_document.assume_role.json }
Related[edit]
See also[edit]
- Terraform IAM resources:
aws_iam_user, aws_iam_group, aws_iam_role, aws_iam_role_policy_attachment
,aws_iam_policy
,aws_iam_role_policy, aws_iam_user_policy, aws_iam_user_policy_attachment
,aws_iam_access_key, aws_iam_group_policy, aws_iam_group_policy_attachment, aws_iam_openid_connect_provider
- Terraform AWS: provider, resources, modules, data sources, VPC, IAM, Net, EC2, S3, Route53, ACM, CloudWatch, SES, RDS, ECS,
awscc, autoscaling, EKS
Advertising: