-
Notifications
You must be signed in to change notification settings - Fork 34
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
add user endpoint for managing user groups permissions #409
Conversation
Still working to figure out why when I add groups to permissions that its not idompotent, always shows changed. |
Co-authored-by: Joe Wesch <10467633+joewesch@users.noreply.github.com>
Co-authored-by: Joe Wesch <10467633+joewesch@users.noreply.github.com>
Co-authored-by: Joe Wesch <10467633+joewesch@users.noreply.github.com>
Co-authored-by: Joe Wesch <10467633+joewesch@users.noreply.github.com>
The tests are not fully running, maybe because of the merge conflicts? |
okay, think I cleaned up everything pending and fixed merge conflict |
Co-authored-by: Joe Wesch <10467633+joewesch@users.noreply.github.com>
object_types: | ||
- "dcim.device" | ||
state: present | ||
register: test_three |
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.
Please add the users
and groups
fields to ensure they work as well.
This will probably require:
- Adding items to the nautobot_populate.py file to create the user and group that you will use
set_fact
at the top of this file to look up the user and group- this will require you to add the endpoints to the lookup plugin
Co-authored-by: Joe Wesch <10467633+joewesch@users.noreply.github.com>
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.
I pushed up a change to convert groups
on admin_permission to just str
elements instead of raw
. Technically, both - name: foo
and - foo
work, but since there are no other keys for a group it doesn't make much sense to have it be raw
.
Full tests successful: https://github.com/nautobot/nautobot-ansible/actions/runs/10812691163 |
The
User
model / endpoint was added awhile ago in NB core, this allows for some base level support for some of those models. SpecificallyUser, Groups, Permissions
. Did NOT implementpassword
parameter for user to avoid potential security implications, also did NOT add the Token model to avoid potential security implementation with that.