From 62dca61b645f0e92d8c95d47b61629c5f5aae66a Mon Sep 17 00:00:00 2001 From: aviau Date: Sat, 13 Dec 2014 22:25:52 -0500 Subject: [PATCH] Remove influxdb from Dockerfile Change-Id: Ifa6908a7a431710c361b566b51c23b8ae3ae3568 --- Dockerfile | 14 +------------- fig.yml | 5 +++++ .../docker/etc/apache2/conf-enabled/influxdb.conf | 4 ++-- tools/docker/etc/shinken/modules/influxdb.cfg | 2 +- 4 files changed, 9 insertions(+), 16 deletions(-) diff --git a/Dockerfile b/Dockerfile index a5db7da..5edbe1c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -32,15 +32,8 @@ RUN rm -rf /etc/shinken ADD tools/docker/etc/shinken /etc/shinken RUN chown -R root:shinken /etc/shinken -### Influxdb -RUN apt-get install -y wget curl -RUN wget http://s3.amazonaws.com/influxdb/influxdb_latest_amd64.deb -RUN useradd influxdb # We should remove this when issue is fixed (https://github.com/influxdb/influxdb/issues/670) -RUN dpkg -i influxdb_latest_amd64.deb -RUN service influxdb start && until curl -X POST 'http://localhost:8086/db?u=root&p=root' -d '{"name": "grafana"}'; do echo "Try again"; sleep 2; done && curl -X POST 'http://localhost:8086/db?u=root&p=root' -d '{"name": "db"}' # We should remove the sleep when this issue is fixed: https://github.com/influxdb/influxdb/issues/805 - ### Grafana -RUN apt-get install -y apache2 +RUN apt-get install -y apache2 wget RUN wget http://grafanarel.s3.amazonaws.com/grafana-1.7.0-rc1.tar.gz RUN tar xvf grafana-1.7.0-rc1.tar.gz RUN mv grafana-1.7.0-rc1 /var/www/html/grafana @@ -74,11 +67,6 @@ ADD tools/docker/etc/supervisor /etc/supervisor # Shinken WEBUI EXPOSE 7767 -# Influxdb -EXPOSE 8083 -EXPOSE 8084 -EXPOSE 8086 - # Grafana EXPOSE 80 diff --git a/fig.yml b/fig.yml index 5e914e3..b975ded 100644 --- a/fig.yml +++ b/fig.yml @@ -2,5 +2,10 @@ surveil: build: . links: - mongo + - influxdb mongo: image: mongo +influxdb: + image: tutum/influxdb + environment: + PRE_CREATE_DB: "db;grafana" diff --git a/tools/docker/etc/apache2/conf-enabled/influxdb.conf b/tools/docker/etc/apache2/conf-enabled/influxdb.conf index 240799b..b0823b2 100644 --- a/tools/docker/etc/apache2/conf-enabled/influxdb.conf +++ b/tools/docker/etc/apache2/conf-enabled/influxdb.conf @@ -2,5 +2,5 @@ # ProxyPass /influxdb/db/grafana http://localhost:8086/db/grafana ProxyRequests Off -ProxyPass /influxdb/ http://localhost:8086/ -ProxyPassReverse /influxdb/ http://localhost:8086/ +ProxyPass /influxdb/ http://influxdb:8086/ +ProxyPassReverse /influxdb/ http://influxdb:8086/ diff --git a/tools/docker/etc/shinken/modules/influxdb.cfg b/tools/docker/etc/shinken/modules/influxdb.cfg index bfb1394..8c22a87 100644 --- a/tools/docker/etc/shinken/modules/influxdb.cfg +++ b/tools/docker/etc/shinken/modules/influxdb.cfg @@ -6,7 +6,7 @@ define module { module_name mod-influxdb module_type influxdb_perfdata - host localhost + host influxdb port 8086 user root password root