docker-grafana

Build

To create the image bbinet/grafana, execute the following command in thedocker-grafana folder:

docker build -t bbinet/grafana .

You can now push the new image to the public registry:

docker push bbinet/grafana

Configure and run

You can configure the Grafana running container with the following requiredenvironment variables:

METRICSDB: InfluxDB database in which grafana should query the metrics.

METRICSDB_USER: Username to use to connect to the above database (thepassword will be read from InfluxDB docker environment variables).

GRAFANADB: InfluxDB database in which grafana should persist all thedashboards.

GRAFANADB_USER: Username to use to connect to the above database (thepassword will be read from InfluxDB docker environment variables).

HTTP_USER: Username for HTTP auth.

HTTP_PASSWORD: Password for HTTP auth.

Then when starting your InfluxDB container, you will want to bind ports 80from the Grafana container to the host external ports.The container should also be linked with the InfluxDB container so that it canread the users passwords from the environment variables.