From 9eff12d1ad24f4ddc2fd3c166d0ec767572d5db6 Mon Sep 17 00:00:00 2001 From: Liam Young Date: Mon, 17 Feb 2020 11:08:20 +0000 Subject: [PATCH] If endpoint switches to https tell nova-cc If the charm has joined the certificate relation and switched its endpoint to using https then it needs to tell nova-cc as it currently gets its neutron endpoint from the neutron-api relation and not the catalogue. Change-Id: Idb1dbf8cbc344ef3f3bf3b6f463e55729a9ff63c --- hooks/neutron_api_hooks.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hooks/neutron_api_hooks.py b/hooks/neutron_api_hooks.py index 1e19aeb6..c6d87858 100755 --- a/hooks/neutron_api_hooks.py +++ b/hooks/neutron_api_hooks.py @@ -782,6 +782,10 @@ def certs_joined(relation_id=None): def certs_changed(relation_id=None, unit=None): process_certificates('neutron', relation_id, unit) configure_https() + # If endpoint has switched to https, need to tell + # nova-cc + for r_id in relation_ids('neutron-api'): + neutron_api_relation_joined(rid=r_id) @hooks.hook('pre-series-upgrade')