-
Notifications
You must be signed in to change notification settings - Fork 9
Us01 user info module #74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
plugins/modules/user_info.py
Outdated
role_uuids: | ||
- 38b346c6-a626-444b-b6ab-92ecd671afc0 | ||
- 7224a2bd-5a08-4b99-a0de-9977089c66a4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Role uuid does not tell much. I guess later we will need to add also a role name. But dedicated role_info module is out of scope in this phase, so I want only to have format that will allow future modification in backward compatible way.
If today we output:
sample:
- fullname: xlab
roles:
- uuid: 38b346c6-a626-444b-b6ab-92ecd671afc0
- uuid: 7224a2bd-5a08-4b99-a0de-9977089c66a4
And in future we can extend with (role) name:
sample:
- fullname: xlab
roles:
- uuid: 38b346c6-a626-444b-b6ab-92ecd671afc0
name: admin
- uuid: 7224a2bd-5a08-4b99-a0de-9977089c66a4
name: backup
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update @PolonaM: please include role name in user_info output. Also when creating a new user, roles will need to be selected, and role will be identified by name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@justinc1 Thanks for the comments! I added role name to the output. I also added option username to the module.
60acd10
to
cbd0857
Compare
- ansible.builtin.assert: | ||
that: | ||
- users.records != [] | ||
- "{{ users.records[0].keys() | sort == ['fullname', 'roles', 'session_limit', 'username', 'uuid'] }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(users.records[0].keys() | sort) == ['full_name', 'roles', 'session_limit', 'username', 'uuid']
"{{
not needed, full_name vs fullname
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tanks for the comment, integration test fixed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor changes
6786839
to
32218f0
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you :)
Added user_info module