2017-05-03 00:03:51 +02:00
|
|
|
FROM node:6-alpine
|
2016-05-09 19:19:35 +02:00
|
|
|
|
2017-05-03 00:03:51 +02:00
|
|
|
ENV APPDIR /usr/local/app
|
2016-05-09 19:19:35 +02:00
|
|
|
|
2017-05-03 00:03:51 +02:00
|
|
|
RUN mkdir -p "$APPDIR"
|
|
|
|
WORKDIR $APPDIR
|
|
|
|
COPY . $APPDIR
|
2017-01-14 21:51:18 +01:00
|
|
|
RUN npm install
|
2016-05-09 19:19:35 +02:00
|
|
|
|
2017-01-14 21:51:18 +01:00
|
|
|
RUN mkdir -p /verdaccio/storage /verdaccio/conf
|
2016-05-09 19:19:35 +02:00
|
|
|
ADD conf/docker.yaml /verdaccio/conf/config.yaml
|
|
|
|
|
2017-01-14 21:51:18 +01:00
|
|
|
RUN addgroup -S verdaccio && adduser -S -g verdaccio verdaccio && \
|
2017-05-03 00:03:51 +02:00
|
|
|
chown -R verdaccio:verdaccio "$APPDIR" && \
|
|
|
|
chown -R verdaccio:verdaccio /verdaccio
|
2017-01-14 21:51:18 +01:00
|
|
|
|
|
|
|
USER verdaccio
|
|
|
|
|
2016-05-09 19:19:35 +02:00
|
|
|
EXPOSE 4873
|
|
|
|
|
2017-01-14 21:51:18 +01:00
|
|
|
VOLUME ["/verdaccio"]
|
2016-05-09 19:19:35 +02:00
|
|
|
|
2017-05-03 00:03:51 +02:00
|
|
|
CMD ["sh", "-c", "${APPDIR}/bin/verdaccio --config /verdaccio/conf/config.yaml --listen 0.0.0.0:4873"]
|