From 38c082357b5d654c84398a42af83983ba526e347 Mon Sep 17 00:00:00 2001 From: Julian Simioni Date: Thu, 22 Mar 2018 12:11:19 -0400 Subject: [PATCH] Remove EXPOSE command from Dockerfile Since we use the `PORT` env var to configure the port, this value will often be out of date. It leads to some confusing output in, for example `docker-compose ps` when using a port other than the default: ``` julian@manhattan ~/repos/pelias/dockerfiles $ docker-compose ps Name Command State Ports --------------------------------------------------------------------------------------------------------------------- pelias_api ./bin/start Up 3100/tcp, 0.0.0.0:4000->4000/tcp ``` Notice how the Ports section shows 3100, even though nothing is running on that port in the container, because the `PORT` env var was set to 4000. --- Dockerfile | 2 -- 1 file changed, 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index aa21a067..dc7836e0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,8 +6,6 @@ USER pelias # maintainer information LABEL maintainer="pelias.team@gmail.com" -EXPOSE 3100 - # Where the app is built and run inside the docker fs ENV WORK=/home/pelias WORKDIR ${WORK}