From 391ca3e3b536d98fa34c34cf32bc96ae8746edb3 Mon Sep 17 00:00:00 2001 From: polarathene <5098581+polarathene@users.noreply.github.com> Date: Sat, 25 Sep 2021 16:47:46 +1200 Subject: [PATCH] fix(Dockerfile): Remove `VOLUME` in Dockerfile Anonymous volumes are discouraged for reliable persistence. Users should use named volumes or bind mounts instead. Potentially breaking change, users can also use explicit anonymous volumes instead of relying on implicit anonymous volumes. `nginx-proxy` really should not be creating implicit anonymous volumes as in most cases it is undesirable. `git blame` reveals this was added in 2014 by jwilder, with a message that implies implicit anonymous volumes was never intended.. --- Dockerfile | 2 -- Dockerfile.alpine | 2 -- 2 files changed, 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 5642e2c..a08f223 100644 --- a/Dockerfile +++ b/Dockerfile @@ -70,7 +70,5 @@ WORKDIR /app/ ENV DOCKER_HOST unix:///tmp/docker.sock -VOLUME ["/etc/nginx/certs"] - ENTRYPOINT ["/app/docker-entrypoint.sh"] CMD ["forego", "start", "-r"] diff --git a/Dockerfile.alpine b/Dockerfile.alpine index 546de81..1281f8f 100644 --- a/Dockerfile.alpine +++ b/Dockerfile.alpine @@ -67,7 +67,5 @@ WORKDIR /app/ ENV DOCKER_HOST unix:///tmp/docker.sock -VOLUME ["/etc/nginx/certs"] - ENTRYPOINT ["/app/docker-entrypoint.sh"] CMD ["forego", "start", "-r"]