-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
38 lines (34 loc) · 1.11 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
FROM alpine
MAINTAINER Dávid Halász <[email protected]>
ENV CRYSTAL_ENV production
ENV PORT 8090
RUN mkdir -p /opt/silvio
COPY . /opt/silvio
WORKDIR /opt/silvio
RUN apk add crystal \
shards \
libressl-dev \
libevent-dev \
musl-dev \
postgresql-dev \
zlib-dev \
libevent \
libgc++ \
gc \
pcre \
postgresql-libs && \
\
shards build silvio-server && \
\
apk del crystal \
shards \
libressl-dev \
libevent-dev \
musl-dev \
postgresql-dev \
zlib-dev && \
\
adduser -S silvio && \
addgroup -S silvio
USER silvio:silvio
CMD bin/silvio-server -b 0.0.0.0 -p $PORT -d $DATABASE_PATH