-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
46 lines (41 loc) · 1.16 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
FROM golang as builder
ARG VERSION=0.8.4
WORKDIR /tmp
RUN set -ex; \
# wget -O src.tar.gz https://github.com/ajvb/kala/archive/v${VERSION}.tar.gz; \
# tar -xzf src.tar.gz; \
# mv kala-${VERSION} kala; \
# Because of https://github.com/ajvb/kala/pull/250, temporary use my personal repo
git clone https://github.com/ajvb/kala.git; \
cd kala; \
CGO_ENABLED=0 go build -o /tmp/main
FROM sstc/headful-chromium:latest
RUN set -ex; \
apt-get update; \
DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y \
tini \
iputils-ping \
dnsutils \
rsync \
curl \
jq \
; \
# In the mean time, install all famous script languages
curl -fsSL https://deb.nodesource.com/setup_lts.x | bash -; \
DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y \
php \
ruby \
lua5.3 \
; \
apt-get clean; \
rm -rf /var/lib/apt/lists/*
RUN set -e; \
npm -g install \
node-fetch
ENTRYPOINT ["tini", "--"]
COPY --from=builder /tmp/main /usr/local/bin/kala
COPY --from=builder /tmp/kala/webui /app/webui
WORKDIR /app
# change default db root path to /tmp, let user mount the volume easier
CMD ["kala", "serve", "--bolt-path=/tmp"]
EXPOSE 8000