-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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 keycloak_realm_rolemapping module to map realm roles to groups #7663
Add keycloak_realm_rolemapping module to map realm roles to groups #7663
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
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.
Thanks for your contribution!
For the errors regarding authors, see https://github.com/ansible-collections/community.general/blob/main/CONTRIBUTING.md#creating-new-modules-or-plugins.
Also note that new modules must always come with tests (unit tests, integration tests, or both). Some existing keycloak_*
modules have unit tests (tests/unit/plugins/modules/test_keycloak_*.py
), some others have integration tests (tests/integration/targets/keycloak_*
).
Hello @felixfontein, Thank you for your feedback. I'll continue working on the issues mentioned. I just wanted to get this out the door before people start duplicating work. I was aware this PR isn't perfect yet. |
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
* mhuysamen submitted #7645 * Gaetan2907 authored keycloak_client_rolemapping.py which I took as a basis
I'm not sure what to do about this error regarding
|
Hello @felixfontein, The integration tests are successful when I run them locally with docker. I think I'm ready for your review, apart from that failing "third-party check" above which seems to have an issue with "TASK [Confirm collection can be imported into galaxy]". I'm not aware of any reason why it would fail with regard to my changes. |
The |
That was a bug in galaxy-importer that got fixed in ansible/galaxy-importer#252. |
Co-authored-by: Felix Fontein <[email protected]>
If nobody objects, I'll merge this in ~a week. |
Backport to stable-8: 💚 backport PR created✅ Backport PR branch: Backported as #7785 🤖 @patchback |
…7663) * Add keycloak_realm_rolemapping module to map realm roles to groups * Whitespace * Description in plain English * Casing * Update error reporting as per #7645 * Add agross as maintainer of keycloak_realm_rolemapping module * cid and client_id are not used here * Credit other authors * mhuysamen submitted #7645 * Gaetan2907 authored keycloak_client_rolemapping.py which I took as a basis * Add integration tests * With Keycloak 23 realmRoles are only returned if assigned * Remove debug statement * Add test verifying that unmap works when no realm roles are assigned * Add license to readme * Change version number this module was added * Document which versions of the docker images have been tested * Downgrade version_added Co-authored-by: Felix Fontein <[email protected]> --------- Co-authored-by: Felix Fontein <[email protected]> (cherry picked from commit f7bc696)
@agross thanks for your contribution! |
… module to map realm roles to groups (#7785) Add keycloak_realm_rolemapping module to map realm roles to groups (#7663) * Add keycloak_realm_rolemapping module to map realm roles to groups * Whitespace * Description in plain English * Casing * Update error reporting as per #7645 * Add agross as maintainer of keycloak_realm_rolemapping module * cid and client_id are not used here * Credit other authors * mhuysamen submitted #7645 * Gaetan2907 authored keycloak_client_rolemapping.py which I took as a basis * Add integration tests * With Keycloak 23 realmRoles are only returned if assigned * Remove debug statement * Add test verifying that unmap works when no realm roles are assigned * Add license to readme * Change version number this module was added * Document which versions of the docker images have been tested * Downgrade version_added Co-authored-by: Felix Fontein <[email protected]> --------- Co-authored-by: Felix Fontein <[email protected]> (cherry picked from commit f7bc696) Co-authored-by: Alexander Groß <[email protected]>
SUMMARY
For my Keycloak setup I need to be able to map realm roles into groups. Until now this collection does not support this.
ISSUE TYPE
COMPONENT NAME
keycloak_realm_rolemapping
ADDITIONAL INFORMATION
This is a continuation of #5384 which unfortunately was not merged.