๐ Grafana Backup & Restoreยถ
Grafana Backup & Restore HOWTOยถ
This guide explains how to back up and restore Grafana dashboards using the Grafana Backup Tool.
It covers containerized usage with Podman and Docker, including environment variable setup for different environments.
TOCยถ
- ๐๏ธ Grafana Backup \& Restore HOWTO
- TOC
- ๐ Reference
- ๐ฆ Backup Procedure
- โป๏ธ Restore Procedure
Referenceยถ
Backup Procedureยถ
ATnT Environmentยถ
podman run --rm --name grafana-backup-tool \
-e GRAFANA_TOKEN=glsa_6fNo8iIGHHFF2zOs1kW5e0oo3IzcP9RG_c2969a48 \
-e GRAFANA_URL=https://grafana.atnt.tinyrt.com \
-e GRAFANA_ADMIN_ACCOUNT=alexm \
-e GRAFANA_ADMIN_PASSWORD=Sudografana27@ \
-e VERIFY_SSL=True \
-v /Users/alexm/Documents/grafana-bkf/atnt:/opt/grafana-backup-tool/_OUTPUT_ \
ysde/docker-grafana-backup-tool
IL Environmentยถ
podman run --rm --name grafana-backup-tool \
-e GRAFANA_TOKEN=glsa_SdtwWrcebtrJ8L0U8bSaIXsvXR2mRKUY_2baa7a49 \
-e GRAFANA_URL=https://grafana.il.unibeam.com \
-e GRAFANA_ADMIN_ACCOUNT=admin \
-e GRAFANA_ADMIN_PASSWORD="DG[pyltr[yp3]]" \
-e VERIFY_SSL=True \
-v /Users/alexm/Documents/grafana-bkf/IL:/opt/grafana-backup-tool/_OUTPUT_ \
ysde/docker-grafana-backup-tool
Permissions
Ensure the backup directory is writable by the container user:
Restore Procedureยถ
docker run --name grafana-backup-tool \
-e GRAFANA_TOKEN="glsa_6fNo8iIGHHFF2zOs1kW5e0oo3IzcP9RG_c2969a48" \
-e GRAFANA_URL=https://grafana.atnt.tinyrt.com \
-e GRAFANA_ADMIN_ACCOUNT=alexm \
-e GRAFANA_ADMIN_PASSWORD=Sudografana27@ \
-e VERIFY_SSL=True \
-e RESTORE=true \
-v /tmp/backup/:/opt/grafana-backup-tool/_OUTPUT_ \
ysde/docker-grafana-backup-tool
Restore Command Logic
The container entrypoint checks the RESTORE variable and restores from the specified archive file or directory:
Further Reading
See the Grafana Backup Tool documentation for advanced options, cloud storage integration, and troubleshooting.