-
Notifications
You must be signed in to change notification settings - Fork 4
/
Dockerfile
39 lines (29 loc) · 949 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Docker version 1.9.1, build a34a1d5
# Build image using the latest version of Ubuntu from the Docker Hub Ubuntu repository.
FROM ubuntu:16.04
# Declare the MAINTAINER of the Dockerfile
MAINTAINER Ashwin Hegde <ashwin.hegde3@gmail.com>
# Make sure apt is up to date
RUN apt-get update
# Install nodejs and npm
RUN apt-get install -y nodejs nodejs-legacy npm git
# Create app directory
RUN mkdir -p /usr/protocore
WORKDIR /usr/protocore
# Install dependencies at global level
RUN npm install -g grunt-cli
RUN npm install -g bower
# Install app dependencies
COPY package.json /usr/protocore
COPY bower.json /usr/protocore
RUN npm install
RUN bower install --allow-root
# Bundle app source
COPY . /usr/protocore
# Run source build
RUN grunt build
# Your app binds to port 8000 so you'll use the EXPOSE instruction
# to have it mapped by the docker daemon
EXPOSE 8000
# Execute command and start Node.js server
CMD [ "npm", "run", "docker" ]