-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathDockerfile
63 lines (53 loc) · 1.46 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
53
54
55
56
57
58
59
60
61
62
63
#
# Pushpin Dockerfile
#
# https://github.com/johnjelinek/pushpin-docker
#
# Pull the base image
FROM ubuntu:15.10
MAINTAINER John Jelinek IV <john@johnjelinek.com>
ENV PUSHPIN_VERSION 1.6.0
ENV ZURL_VERSION 1.4.10
# Install dependencies
RUN \
apt-get update && \
apt-get install -y pkg-config libqt4-dev libqca2-dev \
libqca2-plugin-ossl libqjson-dev libzmq3-dev python-zmq \
python-setproctitle python-jinja2 python-tnetstring \
python-sortedcontainers mongrel2-core git libcurl4-gnutls-dev
# Build Zurl
RUN \
git clone git://github.com/fanout/zurl.git /zurl && \
cd /zurl && \
git checkout tags/v"$ZURL_VERSION" && \
git submodule init && git submodule update && \
./configure && \
make && \
make install
# Build Pushpin
RUN \
git clone git://github.com/fanout/pushpin.git /pushpin && \
cd /pushpin && \
git checkout tags/v"$PUSHPIN_VERSION" && \
git submodule init && git submodule update && \
make
# Configure Pushpin
RUN \
cd /pushpin && \
cp examples/config/* . && \
sed -i -e 's/localhost:80/app:8080/' routes && \
sed -i -e 's/push_in_http_addr=127.0.0.1/push_in_http_addr=0.0.0.0/' pushpin.conf
# Cleanup
RUN \
apt-get clean && \
rm -fr /var/lib/apt/lists/* && \
rm -fr /tmp/*
# Define working directory
WORKDIR /pushpin
# Define default command
CMD ["/pushpin/pushpin"]
# Expose ports.
# - 7999: HTTP port to forward on to the app
# - 5561: HTTP port to receive real-time messages to update in the app
EXPOSE 7999
EXPOSE 5561