forked from opennaslab/kubespider
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
42 lines (32 loc) · 802 Bytes
/
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
# syntax=docker/dockerfile:1
FROM python:3.11-alpine
RUN touch /.dockerenv
WORKDIR /app
COPY ./kubespider ./kubespider
COPY ./.config ./.config_template
COPY requirements.txt ./
ENV HOME="/app" \
PUID=1000 \
PGID=1000 \
UMASK=022 \
TZ=Asia/Shanghai
RUN set -ex \
&& apk add --no-cache \
nodejs \
npm \
bash \
su-exec \
tzdata \
shadow \
&& python3 -m pip install --upgrade pip \
&& pip install -r requirements.txt \
&& addgroup -S kubespider -g 911 \
&& adduser -S kubespider -G kubespider -h /app -u 911 -s /bin/bash kubespider \
&& rm -rf \
/app/.cache \
/tmp/*
COPY --chmod=755 entrypoint.sh /entrypoint.sh
ENTRYPOINT [ "/entrypoint.sh" ]
CMD ["server"]
VOLUME /app/.config
EXPOSE 3080