Commit b63489a7 authored by Christopher Martin's avatar Christopher Martin Committed by Ward Bell

dockerfile speed optimizations

closes #36
parent 34cd3920
...@@ -11,10 +11,11 @@ RUN mkdir -p /quickstart /home/nodejs && \ ...@@ -11,10 +11,11 @@ RUN mkdir -p /quickstart /home/nodejs && \
chown -R nodejs:nodejs /home/nodejs chown -R nodejs:nodejs /home/nodejs
WORKDIR /quickstart WORKDIR /quickstart
COPY . /quickstart/ COPY package.json typings.json /quickstart/
RUN chown -R nodejs:nodejs /quickstart RUN npm install --unsafe-perm=true
COPY . /quickstart
RUN chown -R nodejs:nodejs /quickstart
USER nodejs USER nodejs
RUN npm install
CMD npm start CMD npm start
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
"lite": "lite-server", "lite": "lite-server",
"typings": "typings", "typings": "typings",
"docker-build": "docker build -t ng2-quickstart .", "docker-build": "docker build -t ng2-quickstart .",
"docker-run": "docker run -it --rm -p 3000:3000 -p 3001:3001 ng2-quickstart", "docker": "npm run docker-build && docker run -it --rm -p 3000:3000 -p 3001:3001 ng2-quickstart",
"postinstall": "typings install" "postinstall": "typings install"
}, },
"license": "ISC", "license": "ISC",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment