Closed tbutler-qontigo closed 1 year ago
There is a comment in the code : // The endpoint api/permissions/groups return also the non template permissions this messes with state of the permissions // To make sure these don't interfere the extra permissions are ignored
Maybe it was a mistake because Application are available with the Developer Edition and the Portofolio in the Enterprise Edition.
@fhusson thank you for the pr!! I will push out v0.15.1 with this change
The
stripPermissions
method inresource_sonarqube_permissions_go
explicitly removesapplicationcreator
andportfoliocreator
.This causes a problem when trying to set group permissions that include them.
Terraform Version
1.3.2
Affected Resource(s)
sonarqube_permissions
Terraform Configuration Files
Expected Behavior
The permissions are set on first
terraform apply
and are unchanged on subsequent callsActual Behavior
Every call to
terraform plan
orterraform apply
after the initial setup decides that my_admin_group_permissions needs to be updated.Steps to Reproduce
Please list the steps required to reproduce the issue, for example:
terraform apply
using the two resources I listed earlierterraform apply
againI believe this is because when terraform comes to check if the resource needs to be updated or not, because
stripPermissions
strips out some permissions, it thinks that the permission list is 2 shorter than it actually is...which does not match with the.tf
file => the resource needs to be updated. And this will happen evey time because the two permissions are always removed.I am unsure of the circumstance under which it makes sense to remove those two permissions but it seems not to be appropriate in the case where the caller is supplying only the
group_name
andpermissions
list