ilijamt/terraform-provider-awx

Feature: Instance groups association with teams

Closed this issue · 4 comments

I would like to see if we could implement roles to team of type instance groups. I didnt find any documenation or any such examples that could point if this is already been developed, but as far as i check it seems we dont have it implemented yet. Would it be possible to get this included in the stack?

Hi @reshifirdous can you point me to the API in question for association? I need to check.

Found it I'll add it to the provider. Looks like it's the only one I missed, the object roles were added in version 23.5.1

data "awx_instance_group" "instance_group" {
name = "default"
}
data "awx_instance_group_object_roles" "instance_group_groups" {
id = data.awx_instance_group.instance_group.id
}
resource "awx_team_associate_role" "team_access_instance_groups" {
team_id = awx_team.team_role.id
role_id = data.awx_instance_group_object_roles.instance_group_groups.roles["Use"]
}

You can try the new releases depending on which version you use.

Let me know if it works for you now?

thanks a ton it did work i overlooked this example. i opened example section didnt paid attention at the end. i am testing things looks good so far. :)
thanks once again for quick response