-
Notifications
You must be signed in to change notification settings - Fork 433
Non-admin access to volumes does not work #1329
Comments
Great issue, thank you for filing it. This is quite annoying and has lead to confusion in a number of situations. |
+1 |
So, any news on this? I'm hitting the same problem and have no clue how to fix this. |
@hmeerlo you can workaround this issue by using the admin credentials instead of user's one, but that's… creepy. |
The bug is here: https://github.com/heketi/heketi/blob/master/apps/glusterfs/app_middleware.go#L39 |
As heketi is now in maintenance mode, and only accepting major bug and security related fixes, we do not expect to implement this change. |
Kind of issue
Bug
Observed behavior
With user (non-admin) credentials the following check is performed:
This prevents the following API from working when "user" credentials are used:
Volume Information
Method: GET
Endpoint:/volumes/{id}
Expand a Volume
Method: POST
Endpoint:/volumes/{id}/expand
Delete Volume
Method: DELETE
Endpoint:/volumes/{id}
In particular it is not possible to get Volume Information or delete a Volume with user credentials. It appears that user credentials were designed with the idea, that kubernetes provisioner can run under user credentials. However a provisioner needs to be able to get information about existing volumes and delete volumes.
In addtion
heketi-cli
commands such asvolume list
issuesGET
on/volumes/{id}
which causes message "Administrator access required" when trying to list volumes under user credentials.Similarly, in kubernets, when creating a persistent volume claim we get "Failed to provision volume with StorageClass glusterfs-storage: failed to create volume: failed to create volume: Administrator access required"
Expected/desired behavior
According to the documentation:
User is supposed to have access to Volume API. This includes Volume Information and Delete Volume API.
Details on how to reproduce (minimal and precise)
Make sure that authentication is turned on for the server.
Run:
Observe:
Information about the environment:
The text was updated successfully, but these errors were encountered: