Skip to content

Commit

Permalink
DOCKER: Fix downloads/ permissions
Browse files Browse the repository at this point in the history
  • Loading branch information
icot committed Dec 17, 2018
1 parent 971b7de commit 2149070
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ FROM gitlab-registry.cern.ch/db/dbod-web-base:latest

MAINTAINER Ignacio Coterillo <[email protected]>

USER node
WORKDIR /opt/dbod/
# Bundle app source
COPY server.js ./dist.tgz /opt/dbod/
COPY package-server.json /opt/dbod/package.json
COPY server/ /opt/dbod/server
RUN tar xvzf dist.tgz
RUN chown node:node /opt/dbod/sessions && chmod 0777 /opt/dbod/sessions
ENV NODE_EXTRA_CA_CERTS=CERN-CA.pem
USER node
RUN tar xvzf dist.tgz >/dev/null 2>&1
RUN mkdir -p /opt/dbod/downloads
RUN chown -R node:node /opt/dbod/sessions /opt/dbod/downloads && chmod 0777 /opt/dbod/sessions /opt/dbod/downloads
EXPOSE 3000
ENV NODE_EXTRA_CA_CERTS=CERN-CA.pem
ENTRYPOINT ["npm", "start"]

0 comments on commit 2149070

Please sign in to comment.