KeystoneRequires.ep_changed() now returns a dictionary rather than
json. As a result KeystoneRequires.endpoint_checksums now throws an
exception when it tries to decode the return from ep_changed.
Change-Id: I440104679c900ce8b67ff1fca1d0ce003e5f0ef4
The new keystone-k8s operator uses the application data bag and
more up-to-date key names for endpoint and authentication information.
Check for this information and then fallback to the existing
keystone charm unit data bag data set if not found.
Update register_endpoints to also provide new application data
bag JSON encoded data when this method is called from a lead
unit. This relies on the type and description of the endpoint
being provided which will require a charm change on adoption.
Change-Id: I921d173c64b12c35f5ffc17270a0fc2bb83891c4
The RelationBase class has been deprecated for some time and
provides no support for interaction with the application data
bag.
Migrate requires interface to Endpoint base class and refactor
as needed.
Change-Id: I82fe7df6c7c3658dd334a830442f1dcbd1e7d7e4
The service_type needs to be added to keystone_authtoken
for access rules (application credentials) to work so it
is now a required parameter.
Related-Bug: #1965967
Change-Id: Ic90de9de13ad2728b9ce9de075c03f7854c417ca
A charm joined to keystone via the identity-service relation can
now specify additional roles that can be granted to admin. This
is done by setting the relation data key `add_role_to_admin` the
value is a comma seperated list of roles that should be granted
to admin.
Change-Id: I5495c350c7ac65f8a67125734dff368577c983f4
Most reactive charms react on identity-service.available but the
current interface distinguishes between available and available.auth. It
is somewhat assumed by most charms that identity-service.available is
equivalent to identity-service.available.auth, as what charms are
concerned with is the ability to authenticate against the cloud.
Collapse the difference between identity-service.available and
identity-service.available.auth.
Continue to set identity-service.available.auth for any charms that may
rely on it.
Change-Id: I494feea5f3ef8706140ce712b1e025e52b0dfbd1
Closes-Bug: #1818113
The mock third party library was needed for mock support in py2
runtimes. Since we now only support py36 and later, we can use the
standard lib unittest.mock module instead.
Note that https://github.com/openstack/charms.openstack is used during tests
and he need `mock`, unfortunatelly it doesn't declare `mock` in its
requirements so it retrieve mock from other charm project (cross dependency).
So we depend on charms.openstack first and when
Ib1ed5b598a52375e29e247db9ab4786df5b6d142 will be merged then CI
will pass without errors.
Depends-On: Ib1ed5b598a52375e29e247db9ab4786df5b6d142
Change-Id: I8ca08483bf40a3092275d5dd0458951a64f239a1
Add support for recent changes to keystone to allow consuming
charms to request notification about endpoint changes.
Change-Id: Icacca3445980cdb866cb0dad90b288ce96e8c460
When passing ``requested_roles`` down the ``identity-service``
relation the Keystone charm will create the listed roles for you.
Useful for charm authors implementing charms with specific role
requirements.
Change-Id: I7c1eedb1e78ffc53ac3e0df81f6b52358dd8dfa5
Closes-Bug: #1813602
This adds back in the unit tests that were removed due to charm-tools
issue #192 [1] where the ignore option was 'ignored' by charm-tools.
This meant that the unit tests could not be ignored, and they ended
up in the built charm which then failed.
[1] https://github.com/juju/charm-tools/issues/192
Change-Id: Idbde830cac9ddc8ee3622fa6b7fd8a88e81e2811
This adds unit tests to the interface-keystone and provides ostestr
support, and a makefile to allow easy 'make lint' and 'make test'
commands. All tests are performed in tox environments. At present this
is py27.