From a006ec69a56e984b79ef4ca50ff148a653585568 Mon Sep 17 00:00:00 2001 From: AlaricChan Date: Wed, 11 Apr 2018 06:38:39 +0000 Subject: [PATCH] Fix NPM 5 build dependency issue --- Dockerfile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index bcfa6e68a..0cfd5ed96 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,17 +9,17 @@ COPY . /RackHD/on-http/ WORKDIR /RackHD/on-http RUN mkdir -p ./node_modules \ - && ln -s /RackHD/on-tasks ./node_modules/on-tasks \ - && ln -s /RackHD/on-core ./node_modules/on-core \ - && ln -s /RackHD/on-core/node_modules/di ./node_modules/di \ && apt-get update \ && apt-get install -y unzip curl \ - && npm install \ && npm install apidoc@^0.12.1 \ + && npm install --production \ && npm run taskdoc \ && /RackHD/on-http/install-web-ui.sh \ && /RackHD/on-http/install-swagger-ui.sh \ - && npm prune --production + && rm -r ./node_modules/on-tasks ./node_modules/on-core ./node_modules/di \ + && ln -s /RackHD/on-tasks ./node_modules/on-tasks \ + && ln -s /RackHD/on-core ./node_modules/on-core \ + && ln -s /RackHD/on-core/node_modules/di ./node_modules/di EXPOSE 9080 9090 VOLUME /RackHD/on-http/static/http/common