keenauth_role

Die Ressource keenauth_role verwaltet eine Rolle der Umgebung und deren vollständige Berechtigungsmenge. Eine Rolle, die zu einer Organisation gehört, ist eine andere Ressource, keenauth_organization_role. Die Data Source keenauth_role liest eine Rolle anhand von id oder key.

resource "keenauth_permission" "invoices_read" {
  api_id = "api_01j9zq3v8c5m2x7k4t6r1n0b3d"
  value  = "invoices:read"
}

resource "keenauth_role" "billing" {
  key         = "billing"
  name        = "Billing"
  description = "Invoices and payment methods."

  permission_ids = [keenauth_permission.invoices_read.id]
}

data "keenauth_role" "billing" {
  key = "billing"
}

Lebenszyklus

Import

Importieren Sie nach Schlüssel oder ID:

tofu import keenauth_role.billing billing
tofu import keenauth_role.billing rol_01j9zq3v8c5m2x7k4t6r1n0b3d