-
Bug
-
Resolution: Done
-
Normal
-
2.2, 2.3, 2.4
-
None
Description
As a superuser I cannot modify a container-push repository via API
This API works on a pulp-only system.
Key Dependency Versions
{
"available_versions":
,
"server_version": "4.4.4",
"galaxy_ng_version": "4.4.4",
"galaxy_importer_version": "0.4.0",
"pulp_core_version": "3.15.9",
"pulp_ansible_version": "0.10.2",
"pulp_container_version": "2.8.6"
}
Steps to Reproduce
❯ curl -kX 'PATCH' \ 'https://FQDN/pulp/api/v3/repositories/container/container-push/6e2fd4fb-cc04-43e6-84c5-6880cbdbea52'/ \ -H 'accept: application/json' \ -H 'Authorization: Basic BASE64CREDS' \ -H 'Content-Type: application/json' \ -d '{ "retain_repo_versions": 1 }'
Actual Behavior
403
{"detail":"You do not have permission to perform this action."}Expected Behavior
200
{"task": "id"}
The superuser must have permissions for the change
NOTES:
Root Cause:
https://github.com/ansible/galaxy_ng/blob/master/galaxy_ng/app/access_control/statements/pulp.py#L177 the specification is missing permissions for update and partial_update
Solution
Include the statements from https://github.com/pulp/pulp_container/blob/main/pulp_container/app/viewsets.py#L971 on galaxy_ng statements