Fixing Relations 89/12589/1
authorMark Beierl <mark.beierl@canonical.com>
Thu, 13 Oct 2022 16:55:26 +0000 (12:55 -0400)
committerMark Beierl <mark.beierl@canonical.com>
Thu, 13 Oct 2022 16:56:42 +0000 (12:56 -0400)
Keystone environment variables were not being set, and
the wrong prometheus password was being used

Change-Id: I18e701f4eb9c583edf7905e7404d96bee8d1d8b1
Signed-off-by: Mark Beierl <mark.beierl@canonical.com>
installers/charm/osm-mon/src/charm.py

index 045fd98..ff111d6 100755 (executable)
@@ -239,10 +239,20 @@ class OsmMonCharm(CharmBase):
             "OSMMON_DATABASE_COMMONKEY": self.config["database-commonkey"],
             # Prometheus/grafana configuration
             "OSMMON_PROMETHEUS_URL": f"http://{self.prometheus_client.hostname}:{self.prometheus_client.port}",
+            "OSMMON_PROMETHEUS_USER": self.prometheus_client.user
+            "OSMMON_PROMETHEUS_PASSWORD": self.prometheus_client.password,
             "OSMMON_GRAFANA_URL": self.config["grafana-url"],
             "OSMMON_GRAFANA_USER": self.config["grafana-user"],
             "OSMMON_GRAFANA_PASSWORD": self.config["grafana-password"],
+            "OSMMON_KEYSTONE_ENABLED": self.config["keystone-enabled"],
+            "OSMMON_KEYSTONE_URL": self.keystone_client.host,
+            "OSMMON_KEYSTONE_DOMAIN_NAME": self.keystone_client.user_domain_name,
+            "OSMMON_KEYSTONE_SERVICE_PROJECT": self.keystone_client.service,
+            "OSMMON_KEYSTONE_SERVICE_USER": self.keystone_client.username ,
+            "OSMMON_KEYSTONE_SERVICE_PASSWORD": self.keystone_client.password,
+            "OSMMON_KEYSTONE_SERVICE_PROJECT_DOMAIN_NAME": self.keystone_client.project_domain_name,
         }
+        logger.info(f"{environment}")
         if self.vca.data:
             environment["OSMMON_VCA_HOST"] = self.vca.data.endpoints
             environment["OSMMON_VCA_SECRET"] = self.vca.data.secret