-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
77 lines (64 loc) · 1.76 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
FROM debian:buster
RUN apt-get -qq update \
&& DEBIAN_FRONTEND=noninteractive \
apt-get -y install --no-install-recommends \
ca-certificates \
&& apt-get clean
RUN echo "deb [trusted=yes] https://apt.fury.io/caddy/ /" \
| tee -a /etc/apt/sources.list.d/caddy-fury.list
RUN export DEBIAN_FRONTEND=noninteractive \
&& apt-get -y update \
&& apt-get -y install \
--no-install-recommends \
bash \
caddy \
cron \
curl \
fcgiwrap \
file \
gettext \
git \
grep \
htop \
jq \
less \
net-tools \
osmium-tool \
procps \
unzip \
util-linux \
uuid-runtime \
vim \
wget \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
RUN export DEBIAN_FRONTEND=noninteractive \
&& apt-get -y update \
&& apt-get -y install \
--no-install-recommends \
nodejs \
npm \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
RUN npm install -g yarn
RUN mkdir -p /osm
COPY ./package.json /openindoor-app/package.json
COPY ./.eslintrc.js /openindoor-app/.eslintrc.js
COPY ./babel.config.js /openindoor-app/babel.config.js
COPY ./tsconfig.json /openindoor-app/tsconfig.json
COPY ./package.json /openindoor-app/package.json
WORKDIR /openindoor-app
RUN yarn install
COPY ./src /openindoor-app/src
COPY ./public /openindoor-app/public
COPY ./tests /openindoor-app/tests
RUN yarn build
RUN mkdir -p /data/www
RUN mv ./dist/* /data/www/
COPY ./Caddyfile /etc/caddy/Caddyfile
# CMD yarn serve --port 3000
COPY ./openindoor-app.sh /openindoor-app/openindoor-app
RUN chmod +x /openindoor-app/openindoor-app
# CMD (caddy fmt /etc/caddy/Caddyfile & caddy run --watch --config /etc/caddy/Caddyfile)
CMD /openindoor-app/openindoor-app
EXPOSE 80