Commit 493d20dd authored by rajat.kulkarni's avatar rajat.kulkarni

Delete samplerole.tf

parent c876553a
Pipeline #26673 failed with stage
in 4 seconds
resource "aws_iam_role_policy" "policy_name"{
name = "policy_name"
role = aws_iam_role.role_ec2.id
policy = jsonencode({
Version = "2012-10-17"
Statement = [{
"Sid": "Statement1",
"Effect": "Allow",
Action = [
"ec2-instance-connect:SendSerialConsoleSSHPublicKey",
"ec2-instance-connect:SendSSHPublicKey",
"autoscaling:ExecutePolicy",
"s3:CreateBucket",
"s3:DeleteBucket"
]
"Resource": ["*" ]
}]
})
}
resource "aws_iam_role" "role_ec2" {
name = "role_ec2"
assume_role_policy = jsonencode({
Version = "2012-10-17"
Statement = [{
"Effect": "Allow"
"Principal": {
"Service": "ec2.amazonaws.com"
}
"Action": "sts:AssumeRole"
}]
})
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment