Created
May 20, 2020 12:45
-
-
Save mraaroncruz/e3cbc283c223b9940d72f1a7193e2ee9 to your computer and use it in GitHub Desktop.
Docker compose for influxdb and grafana
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3" | |
services: | |
influxdb: | |
image: influxdb:latest | |
ports: | |
- "127.0.0.1:8083:8083" | |
- "127.0.0.1:8086:8086" | |
- "127.0.0.1:8090:8090" | |
env_file: | |
- "env.influxdb" | |
restart: always | |
volumes: | |
# Data persistency | |
# sudo mkdir -p /srv/docker/influxdb/data | |
# - /srv/docker/influxdb/data:/var/lib/influxdb | |
# - /etc/ssl:/opt/ssl | |
- ./influxdb/data:/var/lib/influxdb | |
grafana: | |
image: grafana/grafana:latest | |
restart: always | |
ports: | |
- "127.0.0.1:3000:3000" | |
env_file: | |
- "env.grafana" | |
depends_on: | |
- influxdb | |
volumes: | |
- ./grafana/data:/var/lib/grafana | |
# - /srv/docker/grafana/data:/var/lib/grafana |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GF_INSTALL_PLUGINS=grafana-clock-panel,briangann-gauge-panel,natel-plotly-panel,grafana-simple-json-datasource | |
# If used with the nginx / letsencrypt proxy | |
# VIRTUAL_HOST= | |
# LETSENCRYPT_HOST= | |
# LETSENCRYPT_EMAIL= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INFLUXDB_DATA_ENGINE=tsm1 | |
INFLUXDB_REPORTING_DISABLED=false | |
# INFLUXDB_HTTP_HTTPS_ENABLED=true | |
# INFLUXDB_HTTP_HTTPS_CERTIFICATE=/opt/ssl/influxdb-selfsigned.crt | |
# INFLUXDB_HTTP_HTTPS_PRIVATE_KEY=/opt/ssl/influxdb-selfsigned.key | |
INFLUXDB_DB="stats" | |
INFLUXDB_ADMIN_ENABLED=true | |
INFLUXDB_ADMIN_USER=admin | |
INFLUXDB_ADMIN_PASSWORD=admin | |
INFLUXDB_WRITE_USER=wuser | |
INFLUXDB_WRITE_USER_PASSWORD=wuser | |
INFLUXDB_READ_USER=ruser | |
INFLUXDB_READ_USER_PASSWORD=ruser |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment