forked from vikin91/BibSpace
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.dev
45 lines (37 loc) · 1.08 KB
/
Dockerfile.dev
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
FROM alpine:latest as builder
COPY cpanfile /
ENV EV_EXTRA_DEFS -DEV_NO_ATFORK
RUN apk update && \
apk add perl \
perl-io-socket-ssl \
perl-dbd-pg \
perl-dev \
perl-dbd-mysql \
g++ \
make \
wget \
curl \
git \
&& curl -L https://cpanmin.us | perl - App::cpanminus \
&& cpanm --installdeps --notest . \
&& rm -rf /root/.cpanm/* /usr/local/share/man/*
FROM builder as bibspace-base
RUN mkdir -p BibSpace
# Code will be mounted
ENV EV_EXTRA_DEFS -DEV_NO_ATFORK
ENV TZ=Europe/Berlin
RUN apk update \
&& apk add tzdata \
&& mkdir -p /config/etc \
&& cp /usr/share/zoneinfo/Europe/Berlin /etc/localtime \
&& rm -rf /var/cache/apk/*
RUN echo "Europe/Berlin" > /config/etc/timezone
LABEL version="0.5.4"
EXPOSE 8083
HEALTHCHECK --interval=30s --timeout=15s CMD curl --fail http://localhost:8083/system_status || exit 1
FROM bibspace-base as bibspace
# For production
# CMD ["BibSpace/bin/bibspace", "daemon", "-m", "production", "-l", "http://*:8083"]
# For development
WORKDIR /BibSpace
CMD ["morbo", "bin/bibspace", "-l", "http://*:8083"]