Stackedit/Dockerfile

28 lines
549 B
Docker
Raw Normal View History

FROM benweet/stackedit-base
2018-01-18 19:54:54 +00:00
RUN mkdir -p /opt/stackedit/stackedit_v4
WORKDIR /opt/stackedit/stackedit_v4
2018-01-18 19:54:54 +00:00
ENV SERVE_V4 true
ENV V4_VERSION 4.3.21
RUN npm pack stackedit@$V4_VERSION \
&& tar xzf stackedit-*.tgz --strip 1 \
&& yarn \
&& yarn cache clean
WORKDIR /opt/stackedit
COPY package.json /opt/stackedit/
COPY yarn.lock /opt/stackedit/
COPY gulpfile.js /opt/stackedit/
2018-01-18 21:55:59 +00:00
RUN npm install \
&& npm cache clean --force \
2018-01-18 19:54:54 +00:00
&& npm run build
COPY . /opt/stackedit
ENV NODE_ENV production
RUN yarn run build
EXPOSE 8080
CMD [ "node", "." ]