-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile
36 lines (29 loc) · 1.12 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
FROM ubuntu:trusty
MAINTAINER Ben West <[email protected]>
ENV DEBIAN_FRONTEND noninteractive
ENV INTERNAL_PORT=3737
ENV PORT=4747
RUN apt-get update -y
RUN apt-get install -y wget curl git -y
RUN curl -sL https://deb.nodesource.com/setup_dev | sudo bash -
RUN echo "deb http://ppa.launchpad.net/nginx/stable/ubuntu trusty main" | tee /etc/apt/sources.list.d/nginx.list
RUN echo "deb-src http://ppa.launchpad.net/nginx/stable/ubuntu trusty main" | tee /etc/apt/sources.list.d/nginx.list
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys C300EE8C
RUN apt-get update
RUN apt-get install -y python python-software-properties nodejs build-essential nginx ruby
RUN npm install -g node-gyp
ADD . /app
WORKDIR /app
# "configure nginx"
RUN erb nginx.conf.erb | tee /etc/nginx/nginx.conf
# clean things
# RUN cd /app && rm -rf node_modules
# RUN cd /app && npm cache clean
RUN cd /app && npm install
EXPOSE 4747
EXPOSE 3737
RUN /app/setup_docker_guest.sh
# forward request and error logs to docker log collector
# RUN ln -sf /dev/stdout /var/log/nginx/access.log
# RUN ln -sf /dev/stderr /var/log/nginx/error.log
CMD /app/start_container.sh