codimd/deployments/Dockerfile
BoHong Li f1594c56e2
feat: upgrade base image to resolve pcheck issues
1. upgrade node.js version from 8.16.0 to 8.16.2
2. upgrade pcheck to support connection string from environment
3. upgrade pcheck to fix connection string contains underscore might not resolve correctly

Signed-off-by: BoHong Li <raccoon@hackmd.io>
2019-11-28 15:57:31 +08:00

24 lines
794 B
Docker

FROM hackmdio/buildpack:1.0.4 as BUILD
COPY --chown=hackmd:hackmd . .
RUN set -xe && \
git reset --hard && \
git clean -fx && \
yarn install && \
yarn build && \
yarn install --production=true && \
cp ./deployments/docker-entrypoint.sh ./ && \
cp .sequelizerc.example .sequelizerc && \
rm -rf .git .gitignore .travis.yml .dockerignore .editorconfig .babelrc .mailmap .sequelizerc.example \
test docs contribute \
yarn.lock webpack.prod.js webpack.htmlexport.js webpack.dev.js webpack.common.js \
config.json.example README.md CONTRIBUTING.md AUTHORS
FROM hackmdio/runtime:1.0.6
USER hackmd
WORKDIR /home/hackmd/app
COPY --chown=1500:1500 --from=BUILD /home/hackmd/app .
EXPOSE 3000
ENTRYPOINT ["/home/hackmd/app/docker-entrypoint.sh"]