Merge ~aluria/charm-openstack-service-checks/+git/charm-openstack-service-checks:bug/1825951 into ~canonical-bootstack/charm-openstack-service-checks:master

Proposed by Alvaro Uria
Status: Merged
Approved by: Alvaro Uria
Approved revision: 00383c8f417b42cfabf39766fb061eaa2e9a4609
Merged at revision: ec7a85429bdbf705811060b10412cc767d9a1852
Proposed branch: ~aluria/charm-openstack-service-checks/+git/charm-openstack-service-checks:bug/1825951
Merge into: ~canonical-bootstack/charm-openstack-service-checks:master
Diff against target: 17 lines (+7/-0)
1 file modified
reactive/openstack_service_checks.py (+7/-0)
Reviewer Review Type Date Requested Status
Peter Sabaini (community) Approve
Review via email: mp+366581@code.launchpad.net

Commit message

Update the stored credentials on change

Closes-bug: #1825951

To post a comment you must log in.
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Unable to determine commit message from repository - please click "Set commit message" and enter the commit message manually.

Revision history for this message
Alvaro Uria (aluria) wrote :
Revision history for this message
Peter Sabaini (peter-sabaini) wrote :

LGTM in general -- if poss. would suggest to add a test that demonstrates the issue and fix

review: Approve
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change has no commit message, setting status to needs review.

Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change successfully merged at revision ec7a85429bdbf705811060b10412cc767d9a1852

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/reactive/openstack_service_checks.py b/reactive/openstack_service_checks.py
2index 6fc43fd..63f5d62 100644
3--- a/reactive/openstack_service_checks.py
4+++ b/reactive/openstack_service_checks.py
5@@ -105,6 +105,13 @@ def allow_keystone_store_overwrite():
6 clear_flag('openstack-service-checks.stored-creds')
7
8
9+@when('identity-credentials.available.updated')
10+def update_keystone_store():
11+ """when identity-service-relation-changed is triggered, update the stored credentials
12+ """
13+ allow_keystone_store_overwrite()
14+
15+
16 def get_credentials():
17 """Get credential info from either config or relation data
18

Subscribers

People subscribed via source and target branches