-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathDockerfile
30 lines (20 loc) · 924 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
# Open Whisper Systems TextSecure Server
# Build the image with
# docker build --rm -t whisper .
# Run the container in a directory containing the jar/ and config/ dirs
# and the scripts referenced here
#
# docker run -p 8080:8080 -p 8081:8081 -P -v $(pwd):/home/whisper -it whisper
FROM ubuntu:14.10
MAINTAINER Jani Monoses <[email protected]>
RUN DEBIAN_FRONTEND='noninteractive' apt-get update && apt-get install -y redis-server postgresql openjdk-7-jre-headless supervisor
RUN adduser --disabled-password --quiet --gecos Whisper whisper
ENV HOME /home/whisper
WORKDIR /home/whisper
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
RUN /etc/init.d/postgresql start && \
sudo -u postgres psql --command "CREATE USER whisper WITH SUPERUSER PASSWORD 'whisper';" && \
sudo -u postgres createdb -O whisper accountdb && \
sudo -u postgres createdb -O whisper messagedb
EXPOSE 8080 8081
CMD ./run-server