From e14c963bedf307f2d8edfba0e142877921b7771c Mon Sep 17 00:00:00 2001 From: Simon Bruder Date: Tue, 23 Apr 2019 21:11:46 +0000 Subject: [PATCH] add aria2 exporter --- Dockerfile | 2 ++ entrypoint.sh | 2 ++ nginx.conf | 4 ++++ 3 files changed, 8 insertions(+) diff --git a/Dockerfile b/Dockerfile index f11c3f6..cd6c9c1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,6 +20,8 @@ RUN apk add --no-cache \ nginx \ su-exec +COPY --from=sbruder/aria2_exporter /aria2_exporter /aria2_exporter + COPY --from=webui /webui-aria2/docs /srv/www/webui COPY --from=webui /AriaNg/dist /srv/www/webui/ng diff --git a/entrypoint.sh b/entrypoint.sh index e12f94b..0e536bb 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -5,6 +5,8 @@ if ! [ -z $NGINX_LISTEN_SOCKET ]; then fi nginx +ARIA2_URL=http://localhost:6800 /aria2_exporter & + touch /data/torrents chown $UID /data/torrents diff --git a/nginx.conf b/nginx.conf index 45f514d..0bde1b9 100644 --- a/nginx.conf +++ b/nginx.conf @@ -19,4 +19,8 @@ server { proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "Upgrade"; } + + location /metrics { + proxy_pass http://localhost:9578/metrics; + } }