File tree Expand file tree Collapse file tree 3 files changed +9
-1
lines changed Expand file tree Collapse file tree 3 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -139,6 +139,7 @@ Here's the gist of using it directly from github.
139139| cluster\_ name | Cluster name. | ` string ` | n/a | yes |
140140| description | Namespace description | ` string ` | ` "velero-back-up-and-restore" ` | no |
141141| iam\_ deploy | whther or not to deploy iam role | ` bool ` | ` true ` | no |
142+ | iam\_ role\_ name | Name of the Velero IAM role | ` string ` | ` "" ` | no |
142143| name | namespace name | ` string ` | ` "velero" ` | no |
143144| namespace\_ deploy | whther or not to deploy namespace | ` bool ` | ` false ` | no |
144145| openid\_ connect\_ provider\_ uri | OpenID Connect Provider for EKS to enable IRSA. | ` string ` | n/a | yes |
Original file line number Diff line number Diff line change @@ -63,7 +63,8 @@ data aws_iam_policy_document policy {
6363
6464resource aws_iam_role this {
6565 count = var. iam_deploy ? 1 : 0
66- name = format (" %s-%s" , var. cluster_name , var. name )
66+ name = var. iam_role_name == " " ? format (" %s-%s" , var. cluster_name , var. name ) : var. iam_role_name
67+
6768 assume_role_policy = data. aws_iam_policy_document . assume_role . json
6869 tags = merge (var. tags ,
6970 { Attached = var.name },
Original file line number Diff line number Diff line change @@ -65,3 +65,9 @@ variable "bucket" {
6565 description = " Backup and Restore bucket."
6666 type = string
6767}
68+
69+ variable "iam_role_name" {
70+ description = " Name of the Velero IAM role"
71+ type = string
72+ default = " "
73+ }
You can’t perform that action at this time.
0 commit comments