Skip to content
Snippets Groups Projects
Commit ad17d280 authored by PICHOU Kyâne's avatar PICHOU Kyâne
Browse files

Add influxDB and Grafana images

parent 0959197b
No related branches found
No related tags found
No related merge requests found
FROM grafana/grafana:5.2.4
USER grafana
# Grafana
Grafana is a metrics visualization software. Picasoft use it to show some stats from our services. This image is basically just a copy of the one from Docker Hub.
## Configuration
There are some evironment variable you can use to configure the instance :
- `GF_DEFAULT_INSTANCE_NAME` : Name of your Grafana instance
- `GF_SERVER_ROOT_URL` : Root URL of your Grafana instance (eg. `https://grafana.picasoft.net`)
- `GF_SECURITY_ADMIN_USER` : Admin user
- `GF_SECURITY_ADMIN_PASSWORD` : Admin password
## Data persistence
In order to ensure data persistence for your Grafana datasources and dashboard, you should mount a volume on `/var/lib/grafana`. Because Grafana is not execute as root user, you need to specify correct access right to this volume. Is using bind mount, you should do something like `mkdir volumes/grafana && chown 472:472 volumes/grafana`.
FROM influxdb:1.6-alpine
MAINTAINER kyane@kyane.fr
# InfluxDB
InfluxDB is a time series database. Picasoft use this FOSS TSDB to store some metrics about its services. This image is basically just a copy of the official one from Docker Hub.
## Configuration
To automatically create a database at startup, set this environment variable :
- `INFLUXDB_DB` : `DATABASENAME`
### Authentication
It is **really important** to properly configure authentication for InfluxDB HTTP API. First, to enable it, you should set this environment variable :
- `INFLUXDB_HTTP_AUTH_ENABLED` : `true`
Also, you need to use following environment variables in order to create some users :
- `INFLUXDB_ADMIN_USER` : An admin user, use for administration purpose only
- `INFLUXDB_ADMIN_PASSWORD` : Password for admin user
- `INFLUXDB_WRITE_USER` : A user that can be used to write data to your database
- `INFLUXDB_WRITE_USER_PASSWORD` : Password for the write user
- `INFLUXDB_READ_USER` : A user that can be used to read data from your database
- `INFLUXDB_READ_USER_PASSWORD` : Password for the read user
## Data persistence
In order to ensure data persistence for your database, you should mount a volume on `/var/lib/influxdb`
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment