Open abtris opened 9 months ago
A workaround for the time being:
resource "terraform_data" "owner" {
triggers_replace = [
data.azuread_group.the_group.id,
data.azuread_service_principal.the_user.id
]
input = {
group_id = data.azuread_group.the_group.id
owner_id = data.azuread_service_principal.the_user.id
}
provisioner "local-exec" {
command = "az ad group owner add --group ${self.input.group_id} --owner-object-id ${self.input.owner_id}"
}
provisioner "local-exec" {
when = destroy
command = "az ad group owner remove --group ${self.input.group_id} --owner-object-id ${self.input.owner_id}"
}
}
Community Note
Description
Add equivalent for
az ad group owner add
as azuread_group_owner.I think we need way how to modify owners not just members of groups. API exists and used by AZ CLI.
New or Affected Resource(s)
Potential Terraform Configuration
or
References
0000