rancher / terraform-provider-rancher2

Terraform Rancher2 provider
https://www.terraform.io/docs/providers/rancher2/
Mozilla Public License 2.0
253 stars 216 forks source link

[RFE] Global Role inheritedClusterRoles #1341

Open danquack opened 2 months ago

danquack commented 2 months ago

Is your feature request related to a problem? Please describe.

Add the ability to add inherited role to the global resource. Use case can be described in the suse blog

Describe the solution you'd like

Add a new resource field to the schema for inherited_cluster_roles.

resource "rancher2_global_role" "foo" {
  name             = "foo"
  new_user_default = true
  description      = "Terraform global role acceptance test"

  inherited_cluster_roles = ["projects-view"]

  rules {
    api_groups = ["*"]
    resources = ["secrets"]
    verbs = ["create"]
  }
}

Additional context

danquack commented 2 months ago

This was added in #1242 but missing in the documentation. So this should just be a documentation PR.