-
Notifications
You must be signed in to change notification settings - Fork 46
Expand file tree
/
Copy pathDockerfile.rdtool
More file actions
65 lines (56 loc) · 1.37 KB
/
Copy pathDockerfile.rdtool
File metadata and controls
65 lines (56 loc) · 1.37 KB
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
FROM ubuntu:noble
# environment variables
ENV \
APP_USER=xiph \
APP_DIR=/opt/rd_tool \
LC_ALL=C.UTF-8 \
LANG=C.UTF-8 \
LANGUAGE=C.UTF-8 \
DEBIAN_FRONTEND=noninteractive
# add runtime user
RUN \
groupadd --gid 1001 ${APP_USER} && \
useradd --uid 1001 --gid ${APP_USER} --shell /bin/bash --create-home ${APP_USER}
# install runtime dependencies
RUN \
apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
curl \
gosu \
openssh-client \
openssh-server \
python3 \
python3-pip \
python3-numpy \
python3-scipy \
rsync \
&& \
apt-get clean && \
rm -rf /var/lib/apt/lists
# install pinned Python deps (tornado + boto3 from requirements.txt)
RUN \
pip3 install \
tornado==6.1 \
boto3==1.25.2 \
--break-system-packages
# add source
COPY rd_tool ${APP_DIR}/
COPY etc/entrypoint.rdtool /etc/entrypoint.rdtool
RUN chmod +x /etc/entrypoint.rdtool
# set working directory
WORKDIR ${APP_DIR}
# environment variables
# RD_SERVER_URL is set here so awcy_server (Dockerfile) knows the default
# address for this service: http://<rd_tool_host>:${RD_SERVER_PORT}
ENV \
RD_TOOL_DIR=${APP_DIR} \
CONFIG_DIR=/data/conf \
RUNS_DST_DIR=/data/runs \
CODECS_SRC_DIR=/data/src \
WORK_DIR=/data/work \
MEDIAS_SRC_DIR=/data/media \
LOCAL_WORKER_ENABLED=false \
RD_SERVER_PORT=4000
EXPOSE ${RD_SERVER_PORT}
ENTRYPOINT ["sh", "/etc/entrypoint.rdtool"]