aimtheory / grafana-backup-docker

A Docker container that has https://github.com/ysde/grafana-backup-tool

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

grafana-backup-docker

A Docker container that has https://github.com/ysde/grafana-backup-tool

Much thanks to @ysde for such a great tool!

This repository is for a Docker image that is meant to be deployed on Kubernetes as a cron job that runs against a Grafana instance that is also deployed on Kubernetes. But it could be used outside of Kubernetes as well.

When run, this Docker image will clone the https://github.com/ysde/grafana-backup-tool repo and use it to backup all Grafana data to an S3 bucket.

Usage There are 6 environment variable that need to be set when the Docker container is run from this image:

  • GRAFANA_URL
  • GRAFANA_TOKEN
  • AWS_ACCESS_KEY_ID
  • AWS_SECRET_ACCESS_KEY
  • AWS_REGION
  • S3_BUCKET_NAME
docker build -t grafana-backup-docker:latest
docker run -e GRAFANA_URL=[GRAFANA_URL] -e GRAFANA_TOKEN=[GRAFANA_TOKEN] -e AWS_ACCESS_KEY_ID=[AWS_ACCESS_KEY_ID] -e AWS_SECRET_ACCESS_KEY=$[AWS_SECRET_ACCESS_KEY] -e AWS_REGION=[AWS_REGION] -e S3_BUCKET_NAME=[S3_BUCKET_NAME] grafana-backup-docker:latest

About

A Docker container that has https://github.com/ysde/grafana-backup-tool


Languages

Language:Shell 100.0%