https://rancher.com/ logo
Title
a

astonishing-king-67727

05/11/2023, 2:19 PM
Hi everybody - my rancher server is configured for OIDC with keycloak. Using terraform, I provision a new group in keycloak and would like to assign this group to a role in rancher, using i.e.
rancher2_cluster_role_template_binding
. Now, how can I get the
group_id
or
group_principal_id
corresponding to the keycloak group? I was not able to get any results using
data "rancher2_principal"
. Thanks!
Ah, found out: no need to fetch the principal, just add this to the
rancher2_project_role_template_binding
resource:
group_principal_id = "keycloakoidc_<group://whatevergroupname>"
Maybe this should be documented somewhere, could not find it..