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 new keystone module and states based on shade #44713
Conversation
I was asked to create a new PR for this, but here is the previous one for reference |
Thanks Sam! I am adding this to my list to write tests for. This looks great! |
@SamYaple There are some lint errors here: https://jenkins.saltstack.com/job/PR/job/salt-pr-lint-n/16717/violations/ Can you fix those? |
You need to add u ( So that all strings are Unicode. As PY3 is Unicode Strings |
@damon-atkins There is already work in progress to handle the unicode issues. @terminalmage Is working on it right now for Oxygen and his fixes are different than the |
Will fix the lint issues (and gpg sign my commit) |
@SamYaple Were you able to get to those lint fixes? |
Hi @rallytime not sure how the salt team can keep retro fixing contributions, to ensure all text strings are Unicode. terminalmage job will never be done. |
Test cases will be added in future patch
What does this PR do?
This PR adds a new module (keystoneng.py) to supercede keystone.py. It uses the shade library from the openstack project (https://github.com/openstack-infra/shade.git) Shade is a project that has committed to maintaining the same API forever. It may add new features and more efficient ways of doing things, but it will never remove things.
Using shade will abstract the keystone v2/v3 logic away allowing the end user to write states without having to consider which version of the api is it talking to (with the exception of trying to use new features like groups/domains on v2.0 which doesn't support it).
We are making extensive use of **kwargs to help prevent the need to maintain lots of duplicate logic that exists in shade itself.
What issues does this PR fix or reference?
N/A
Tests written?
Not yet