Closed noor409 closed 1 year ago
let me clarify on this one because this description is not very clean,
I as a Sonarqube administrator would like to create a custom quality gate per team I'm managing and assign key users of that team to manage the quality gate.
On the UI, we can assign a Quality Gate to a person, and that person is capable of administer the quality gate rules by then selfs. On this terraform provider, it seems not possible.
Can we have this implemented?
Is this possible with the sonarqube api?
You can assign users the 'gateadmin' role via sonarqube_permissions but i believe this is a global permission not project scoped.
IE: https://github.com/jdamata/terraform-provider-sonarqube/blob/668f89406ac98f3fba565c92e14335f897dd83bf/docs/resources/sonarqube_permissions.md#example-set-codeviewer--user-permissions-on-project-level-for-a-user-called-johndoe
@jdamata it seems to be:
but it does not show on the docs on http://localhost:8000/web_api/api/qualitygates
from my understanding, it's a POST
on /api/qualitygates/add_user
with --data-raw 'gateName=
I also tested for groups and the API is the same:
it's a POST on /api/qualitygates/add_user with --data-raw 'gateName=
perhaps we should have a sonarqube_qualitygate_usergroup_association
resource?
Thanks for the investigation @EvertonSA. I was able to find this in the web_api docs. This api is marked as an 'internal' api.
Use at your own risk; internal services are subject to change or removal without notice.
@jdamata I would like to work on this, do you consider a sonarqube_qualitygate_usergroup_association
a good approach or would you do something different?
Yah that resource sounds good. I'm a little concerned that this API might change significantly. Please be sure to add acceptance tests with the new resource
this issue can be closed
Hi ,
Am able to assign custom quality gates manage permission to specific user/ group via UI,