diff options
Diffstat (limited to 'Services/nodejs/Dockerfile')
-rw-r--r-- | Services/nodejs/Dockerfile | 27 |
1 files changed, 18 insertions, 9 deletions
diff --git a/Services/nodejs/Dockerfile b/Services/nodejs/Dockerfile index dc20d72..2113c64 100644 --- a/Services/nodejs/Dockerfile +++ b/Services/nodejs/Dockerfile @@ -1,12 +1,21 @@ FROM startx/fedora MAINTAINER Christophe LARUE <dev@startx.fr> -RUN dnf -y install nodejs npm python make gcc \ - && dnf clean all \ - && mkdir -p /app \ - && chmod ug+rx /app -VOLUME ["/app"] -WORKDIR /app -COPY app /app -ENV MAIN_APP /app/app.js -ENV NODE_PATH /app/node_modules +USER root +RUN dnf -y install nodejs npm python make gcc && \ + dnf clean all +ENV STARTUPLOG=/data/logs/nodejs/startup.log \ + LOG_PATH=/data/logs/nodejs \ + APP_PATH=/data/nodejs \ + APP_MAIN=/data/nodejs/app.js +COPY *.sh /bin/ +RUN chmod 775 /bin/run.sh && \ + mkdir -p $APP_PATH && \ + mkdir -p $LOG_PATH && \ + touch $STARTUPLOG +COPY ./ $APP_PATH +RUN rm -f $APP_PATH/Dockerfile $APP_PATH/README.md $APP_PATH/run.sh $APP_PATH/docker-compose.yml + +EXPOSE 8000 +VOLUME [$APP_PATH,$LOG_PATH] +CMD ["/bin/run.sh"]
\ No newline at end of file |