Terraform will perform the following actions:
# module.github_openid_connect.module.oidc-github.data.aws_iam_policy_document.assume_role[0] will be read during apply
# (config refers to values not yet known)
<= data "aws_iam_policy_document" "assume_role" {
+ id = (known after apply)
+ json = (known after apply)
+ version = "2012-10-17"
+ statement {
+ actions = [
+ "sts:AssumeRoleWithWebIdentity",
]
+ effect = "Allow"
+ condition {
+ test = "StringEquals"
+ values = [
+ "sts.amazonaws.com",
]
+ variable = "token.actions.githubusercontent.com:aud"
}
+ condition {
+ test = "StringLike"
+ values = [
+ "repo:ORG/*:*",
]
+ variable = "token.actions.githubusercontent.com:sub"
}
+ principals {
+ identifiers = [
+ (known after apply),
]
+ type = "Federated"
}
}
}
# module.github_openid_connect.module.oidc-github.aws_iam_openid_connect_provider.github[0] must be replaced
-/+ resource "aws_iam_openid_connect_provider" "github" {
~ arn = "arn:aws:iam::XXXXXXXXXX:oidc-provider/token.actions.githubusercontent.com" -> (known after apply)
~ client_id_list = [ # forces replacement
- "sts.amazonaws.com",
"https://github.com/ORG",
+ "sts.amazonaws.com",
]
~ id = "arn:aws:iam::XXXXXXXXXXX:oidc-provider/token.actions.githubusercontent.com" -> (known after apply)
tags = {
"BuildBy" = "ORG/Terraform"
"Environment" = "sbx"
"Project" = "ORG"
}
~ url = "token.actions.githubusercontent.com" -> "https://token.actions.githubusercontent.com"
# (2 unchanged attributes hidden)
}
# module.github_openid_connect.module.oidc-github.aws_iam_role.github[0] will be updated in-place
~ resource "aws_iam_role" "github" {
~ assume_role_policy = jsonencode(
{
- Statement = [
- {
- Action = "sts:AssumeRoleWithWebIdentity"
- Condition = {
- StringEquals = {
- "token.actions.githubusercontent.com:aud" = "sts.amazonaws.com"
}
- StringLike = {
- "token.actions.githubusercontent.com:sub" = "repo:ORG/*:*"
}
}
- Effect = "Allow"
- Principal = {
- Federated = "arn:aws:iam::XXXXXXXXXXX:oidc-provider/token.actions.githubusercontent.com"
}
- Sid = ""
},
]
- Version = "2012-10-17"
}
) -> (known after apply)
id = "GithubAssumeRole"
name = "GithubAssumeRole"
tags = {
"BuildBy" = "ORG/Terraform"
"Environment" = "sbx"
"Project" = "ORG"
}
# (9 unchanged attributes hidden)
}
Plan: 1 to add, 1 to change, 1 to destroy.