blob: a4f1d03e8ad162ed35f6bed81b3a02af701ef956 [file] [log] [blame]
Matteo Scandoloe3ed0162016-12-01 10:09:12 -08001# To build use: docker build -t xosproject/xos-nb-rest .
2# To run use: docker run -p 3000:3000 -d xosproject/xos-nb-rest
3
4FROM node:argon
5
6# Set environment variables
7ENV CODE_SOURCE .
8ENV CODE_DEST /var/www
9
10# Create app directory
11WORKDIR ${CODE_DEST}
12
13# Install app dependencies
14COPY ${CODE_SOURCE}/package.json ${CODE_DEST}
15RUN npm install --production
16
17# Bundle app source
18COPY ${CODE_SOURCE}/src ${CODE_DEST}/src
19
20# Create a folder for logs
21RUN mkdir ${CODE_DEST}/logs
22
23EXPOSE 3000
24CMD [ "npm", "start" ]