-
Notifications
You must be signed in to change notification settings - Fork 5
/
Dockerfile
53 lines (32 loc) · 1.13 KB
/
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
40
41
42
43
44
45
46
47
48
49
50
51
52
FROM node:6.10
MAINTAINER Daniel Moll
WORKDIR /home/targets-io
#USER root
#RUN apt-get update && apt-get install -y --no-install-recommends python2.7
# install dockerize
RUN apt-get update && apt-get install -y wget
RUN wget https://github.com/jwilder/dockerize/releases/download/v0.1.0/dockerize-linux-amd64-v0.1.0.tar.gz
RUN tar -C /usr/local/bin -xzvf dockerize-linux-amd64-v0.1.0.tar.gz
# Install targets-io Prerequisites
RUN npm install -g grunt-cli
RUN npm install -g bower
RUN npm install -g forever
RUN apt-get install g++
ENV PYTHON /usr/bin/python2.7
# Install targets-io packages
ADD package.json /home/targets-io/package.json
RUN npm install --production
# Manually trigger bower. Why doesnt this work via npm install?
ADD .bowerrc /home/targets-io/.bowerrc
ADD bower.json /home/targets-io/bower.json
RUN bower install --config.interactive=false --allow-root
# Make everything available for start
ADD . /home/targets-io
ENV NODE_ENV demo
# Port 3000 for server
EXPOSE 3000
COPY docker-entrypoint.sh /entrypoint.sh
#RUN chown -R node:node /entrypoint.sh
RUN chmod +x /entrypoint.sh
#USER node
ENTRYPOINT ["/entrypoint.sh"]