Back to TILs

Grafana --- Reset da senha do admin

Iniciar os containers

cd /opt/docker/docker-compose-influxdb-grafana
docker-compose up -d

Localizar o id do container do ‘/run.sh’

docker ps -a
CONTAINER ID IMAGE                  COMMAND                  CREATED       ...
265059f8820a grafana/grafana:latest "/run.sh"                6 seconds ago ...
637c3d25845f chronograf:latest      "/entrypoint.sh chro…"   6 seconds ago ...
21b3a8d77cae influxdb:latest        "/entrypoint.sh infl…"   7 seconds ago ...

Abrir um shell no container do run.sh (265059f8820a)

docker exec -ti 265059f8820a bash

Trocar a senha usando o grafana-cli

   
bash-5.0$ grafana-cli admin reset-admin-password aqui-vai-a-nova-senha
INFO[01-03|16:34:42] Connecting to DB      logger=sqlstore dbtype=sqlite3
INFO[01-03|16:34:42] Starting DB migration logger=migrator

Admin password changed successfully ✔

Referências