Skip to content

Commit 7c2202d

Browse files
authored
feat: unpin the thumbprints (#538)
1 parent ff258f0 commit 7c2202d

File tree

1 file changed

+5
-16
lines changed

1 file changed

+5
-16
lines changed

gh_oidc_role/main.tf

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -58,20 +58,9 @@ data "aws_iam_policy_document" "oidc_assume_role_policy" {
5858
}
5959

6060
resource "aws_iam_openid_connect_provider" "github" {
61-
count = var.oidc_exists ? 0 : 1
62-
url = local.gh_url
63-
client_id_list = ["sts.amazonaws.com"]
64-
# Manually setting the thumbprint as we are seeing inconsistent thumbprints returned
65-
# https://github.blog/changelog/2023-06-27-github-actions-update-on-oidc-integration-with-aws/
66-
thumbprint_list = distinct(
67-
concat(
68-
[
69-
"1c58a3a8518e8759bf075b76b750d4f2df264fcd",
70-
"6938fd4d98bab03faadb97b34396831e3780aea1",
71-
"f879abce0008e4eb126e0097e46620f5aaae26ad",
72-
],
73-
data.tls_certificate.thumprint.certificates.*.sha1_fingerprint
74-
)
75-
)
76-
tags = local.common_tags
61+
count = var.oidc_exists ? 0 : 1
62+
url = local.gh_url
63+
client_id_list = ["sts.amazonaws.com"]
64+
thumbprint_list = data.tls_certificate.thumprint.certificates[*].sha1_fingerprint
65+
tags = local.common_tags
7766
}

0 commit comments

Comments
 (0)