Skip to content

Commit

Permalink
Docker runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
mayfield committed Dec 7, 2018
1 parent 04cb0c5 commit a037fb3
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.git
target
12 changes: 12 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
FROM maven:3-jdk-8
RUN apt-get update && \
apt-get install -y make && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
WORKDIR /usr/src
COPY . .
RUN make
ENV ACCOUNT_DATABASE_URL=postgres://postgres:@db/account \
MESSAGE_DATABASE_URL=postgres://postgres:@db/message \
REDIS_URL=redis://redis:6379
CMD ["make", "run"]
6 changes: 6 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,9 @@ dbmigrate:

run: dbmigrate
$(RUN) server $(CONFIG)

docker-build:
docker build -t textsecure-server .

docker-run:
docker run -it -p 8080:8080 textsecure-server

0 comments on commit a037fb3

Please sign in to comment.