Files
xterm.js/Dockerfile
T

20 lines
546 B
Docker
Raw Normal View History

2016-12-12 16:37:23 +02:00
FROM node:6.9
MAINTAINER Paris Kasidiaris <paris@sourcelair.com>
2016-12-12 16:37:23 +02:00
# Set the working directory
WORKDIR /usr/src/app
# Set an entrypoint, to automatically install node modules
2016-12-29 16:13:58 +02:00
ENTRYPOINT ["/bin/bash", "-c", "if [[ ! -d node_modules ]]; then npm install; fi; exec \"${@:0}\";"]
2016-12-15 18:26:24 +02:00
CMD ["npm", "run", "dev"]
2016-12-12 16:37:23 +02:00
# First, install dependencies to improve layer caching
COPY package.json /usr/src/app/
RUN npm install
# Add the code
COPY . /usr/src/app
# Run the tests and build, to make sure everything is working nicely
2016-12-29 16:13:58 +02:00
RUN npm run build && npm run test