Commit 34cd3920 authored by Christopher Martin's avatar Christopher Martin Committed by Ward Bell

add dockerfile

parent efa99af6
node_modules/
# To build and run with Docker:
#
# $ docker build -t ng2-quickstart .
# $ docker run -it --rm -p 3000:3000 -p 3001:3001 ng2-quickstart
#
FROM node:latest
RUN mkdir -p /quickstart /home/nodejs && \
groupadd -r nodejs && \
useradd -r -g nodejs -d /home/nodejs -s /sbin/nologin nodejs && \
chown -R nodejs:nodejs /home/nodejs
WORKDIR /quickstart
COPY . /quickstart/
RUN chown -R nodejs:nodejs /quickstart
USER nodejs
RUN npm install
CMD npm start
......@@ -7,6 +7,8 @@
"tsc:w": "tsc -w",
"lite": "lite-server",
"typings": "typings",
"docker-build": "docker build -t ng2-quickstart .",
"docker-run": "docker run -it --rm -p 3000:3000 -p 3001:3001 ng2-quickstart",
"postinstall": "typings install"
},
"license": "ISC",
......@@ -24,4 +26,4 @@
"typescript": "^1.8.9",
"typings":"^0.7.11"
}
}
\ No newline at end of file
}
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