page_title | subcategory | description |
---|---|---|
coderd_group Data Source - terraform-provider-coderd |
An existing group on the Coder deployment. |
An existing group on the Coder deployment.
// Get a group on the provider default organization by `id`
data "coderd_group" "employees" {
id = "abcd-efg-hijk"
}
// Get a group on the provider default organization by `name` + `organization_id`
data "coderd_group" "bosses" {
name = "bosses"
}
// Use them to apply ACL to a template
resource "coderd_template" "example" {
name = "example-template"
versions = [/* ... */]
acl = {
groups = [
{
id = data.coderd_group.employees.id
role = "use"
},
{
id = data.coderd_group.bosses.id
role = "admin"
}
]
users = []
}
}
id
(String) The ID of the group to retrieve. This field will be populated if a name and organization ID is supplied.name
(String) The name of the group to retrieve. This field will be populated if an ID is supplied.organization_id
(String) The organization ID that the group belongs to. This field will be populated if an ID is supplied. Defaults to the provider default organization ID.
avatar_url
(String)display_name
(String)members
(Attributes Set) Members of the group. (see below for nested schema)quota_allowance
(Number) The number of quota credits to allocate to each user in the group.source
(String) The source of the group. Eitheroidc
oruser
.
Read-Only:
created_at
(Number) Unix timestamp of when the member was created.email
(String)id
(String)last_seen_at
(Number) Unix timestamp of when the member was last seen.login_type
(String) The login type of the member. Can beoidc
,token
,password
,github
ornone
.status
(String) The status of the member. Can beactive
,dormant
orsuspended
.username
(String)