during the process of discontinuing our node we need to retrieve the user emails in order to notify them to migrate their VM's. We have tried using keystone user-list after sourcing our openrc config file but to no avail. Is there a command sequence we should use in order to retrieve what we need?
Asked
Active
Viewed 70 times
1 Answers
0
There is an way to get the information about the users that can be using your node. The steps that you should follow are the following:
- Get the id of your region from the GET to http://cloud.lab.fiware.org:4730/v3/OS-EP-FILTER/endpoint_groups
- Get the complete list of projects in your region: GET to http://cloud.lab.fiware.org:4730/v3/OS-EP-FILTER/endpoint_groups/{{Region-Id}}/projects where Region-id comes from endpoints_groups[i].id in the previous JSON response.
- Get the user of those project, for each project: GET to http://cloud.lab.fiware.org:4730/v3/role_assignments?scope.project.id={{project_id}}, where project_id comes from projects[i].id in the previous JSON response.
- Get detailed information of the user: GET to http://cloud.lab.fiware.org:4730/v3/users/{{user-id} where user-id comes from role_assignments[i].user.id in the previous JSON response.
Keep in mind that all the operations have to be done with the corresponding X-Auth-Token.
I hope that it can help you.

flopez
- 620
- 1
- 4
- 9
-
Please take a look to the script implementation in https://github.com/telefonicaid/fiware-skuld/tree/develop/scripts/userListPerRegion repository – flopez Feb 18 '16 at 08:00