canonical / grafana-k8s-operator

This charmed operator automates the operational procedures of running Grafana, an open-source visualization toolkit, on Kubernetes.
https://charmhub.io/grafana-k8s
Apache License 2.0
6 stars 22 forks source link

Password shown on action changes after scaling #64

Open zmraul opened 2 years ago

zmraul commented 2 years ago

Hello!

After deploying the cos-lite bundle:

juju add-model cos
juju deploy cos-lite --channel=edge --trust

I can get the dashboard password with:

juju run-action grafana get-admin-password

If I scale down the grafana app with:

juju remove-unit grafana --num-units 1

and then scale it back up:

juju add-unit grafana --num-units 1

Using get-admin-password shows a different one, but the dashboard is accessible with the old one.

simskij commented 2 years ago

but the dashboard is accessible with the old one.

This sounds odd.

By the looks of it, you deployed grafana with 1 unit, scaled it down to 0, and then scaled it up to 1 again, which should rewrite the config file and reset both the password returned by get-admin-password and the actual password of the grafana UI.

From what I can tell, this isn't really addressed by the PR linked by @rbarry?