Skip to content

Commit

Permalink
fix: add oidc input to assume role policy (#671)
Browse files Browse the repository at this point in the history
  • Loading branch information
naihsuanshao authored Oct 31, 2024
1 parent d64e240 commit 4d41154
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
1 change: 1 addition & 0 deletions aws-iam-role-s3-readonly/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ module "assume_role_policy" {
source = "../aws-assume-role-policy"
source_account_ids = var.source_account_ids
saml_idp_arns = var.saml_idp_arns
oidc = var.oidc
env = var.env
owner = var.owner
service = var.service
Expand Down
13 changes: 13 additions & 0 deletions aws-iam-role-s3-readonly/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,19 @@ variable "saml_idp_arns" {
description = "The AWS SAML IDP arns to establish a trust relationship. Ignored if empty or not provided."
}

variable "oidc" {
type = list(object(
{
idp_arn : string, # the AWS IAM IDP arn
client_ids : list(string), # a list of oidc client ids
provider : string # your provider url, such as foo.okta.com
}
))

default = []
description = "A list of AWS OIDC IDPs to establish a trust relationship for this role."
}

variable "project" {
type = string
description = "Project for tagging and naming. See [doc](../README.md#consistent-tagging)"
Expand Down

0 comments on commit 4d41154

Please sign in to comment.