From b1625a08a0603388b7f4c2275d595fe2753ddc90 Mon Sep 17 00:00:00 2001 From: stuart nelson Date: Thu, 5 Apr 2018 16:25:45 +0200 Subject: [PATCH] Provide default working config for artifacts (#1313) --- .promu.yml | 2 +- Dockerfile | 11 +++++------ Procfile | 6 +++--- examples/ha/{alertmanager.yaml => alertmanager.yml} | 0 4 files changed, 9 insertions(+), 10 deletions(-) rename examples/ha/{alertmanager.yaml => alertmanager.yml} (100%) diff --git a/.promu.yml b/.promu.yml index a5423631..905e6dd9 100644 --- a/.promu.yml +++ b/.promu.yml @@ -15,7 +15,7 @@ build: -X {{repoPath}}/vendor/github.com/prometheus/common/version.BuildDate={{date "20060102-15:04:05"}} tarball: files: - - doc/examples/simple.yml + - examples/ha/alertmanager.yml - LICENSE - NOTICE crossbuild: diff --git a/Dockerfile b/Dockerfile index 7ae217c9..ee208723 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,13 +1,12 @@ FROM prom/busybox:latest MAINTAINER The Prometheus Authors -COPY amtool /bin/amtool -COPY alertmanager /bin/alertmanager -COPY doc/examples/simple.yml /etc/alertmanager/config.yml +COPY amtool /bin/amtool +COPY alertmanager /bin/alertmanager +COPY examples/ha/alertmanager.yml /etc/alertmanager/alertmanager.yml EXPOSE 9093 VOLUME [ "/alertmanager" ] -WORKDIR /alertmanager +WORKDIR /etc/alertmanager ENTRYPOINT [ "/bin/alertmanager" ] -CMD [ "--config.file=/etc/alertmanager/config.yml", \ - "--storage.path=/alertmanager" ] +CMD [ "--storage.path=/alertmanager" ] diff --git a/Procfile b/Procfile index 88f211b2..ab15cfc2 100644 --- a/Procfile +++ b/Procfile @@ -1,5 +1,5 @@ -a1: ./alertmanager --log.level=debug --storage.path=$TMPDIR/a1 --web.listen-address=:9093 --cluster.listen-address=127.0.0.1:8001 --config.file=examples/ha/alertmanager.yaml -a2: ./alertmanager --log.level=debug --storage.path=$TMPDIR/a2 --web.listen-address=:9094 --cluster.listen-address=127.0.0.1:8002 --cluster.peer=127.0.0.1:8001 --config.file=examples/ha/alertmanager.yaml -a3: ./alertmanager --log.level=debug --storage.path=$TMPDIR/a3 --web.listen-address=:9095 --cluster.listen-address=127.0.0.1:8003 --cluster.peer=127.0.0.1:8001 --config.file=examples/ha/alertmanager.yaml +a1: ./alertmanager --log.level=debug --storage.path=$TMPDIR/a1 --web.listen-address=:9093 --cluster.listen-address=127.0.0.1:8001 --config.file=examples/ha/alertmanager.yml +a2: ./alertmanager --log.level=debug --storage.path=$TMPDIR/a2 --web.listen-address=:9094 --cluster.listen-address=127.0.0.1:8002 --cluster.peer=127.0.0.1:8001 --config.file=examples/ha/alertmanager.yml +a3: ./alertmanager --log.level=debug --storage.path=$TMPDIR/a3 --web.listen-address=:9095 --cluster.listen-address=127.0.0.1:8003 --cluster.peer=127.0.0.1:8001 --config.file=examples/ha/alertmanager.yml wh: go run ./examples/webhook/echo.go diff --git a/examples/ha/alertmanager.yaml b/examples/ha/alertmanager.yml similarity index 100% rename from examples/ha/alertmanager.yaml rename to examples/ha/alertmanager.yml