2023-08-28 20:38:09 +08:00
|
|
|
FROM python:3.11.5-alpine3.18
|
2023-06-06 15:22:33 +08:00
|
|
|
|
|
|
|
COPY --chmod=775 start.sh /start.sh
|
|
|
|
|
2023-07-28 20:05:10 +08:00
|
|
|
ENV RECORDING_VERSION v17.0.3
|
2023-06-27 16:59:20 +08:00
|
|
|
ENV ALLOW_ALL false
|
2023-06-27 19:13:15 +08:00
|
|
|
ENV HPB_PROTOCOL https
|
2023-06-27 16:59:20 +08:00
|
|
|
ENV SKIP_VERIFY false
|
2023-07-18 16:01:24 +08:00
|
|
|
ENV HPB_PATH /standalone-signaling/
|
2023-06-06 19:43:06 +08:00
|
|
|
|
2023-06-06 15:22:33 +08:00
|
|
|
RUN set -ex; \
|
|
|
|
apk add --no-cache \
|
|
|
|
ca-certificates \
|
|
|
|
tzdata \
|
|
|
|
bash \
|
|
|
|
xvfb \
|
|
|
|
ffmpeg \
|
|
|
|
firefox \
|
|
|
|
bind-tools \
|
|
|
|
netcat-openbsd \
|
|
|
|
git \
|
|
|
|
wget \
|
|
|
|
shadow \
|
2023-06-06 17:27:52 +08:00
|
|
|
pulseaudio \
|
2023-06-06 15:22:33 +08:00
|
|
|
openssl; \
|
|
|
|
# chromium chromium-chromedriver?
|
|
|
|
apk add --no-cache geckodriver --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing; \
|
|
|
|
useradd -d /tmp --system recording; \
|
|
|
|
# Give root a random password
|
|
|
|
echo "root:$(openssl rand -base64 12)" | chpasswd; \
|
2023-06-06 19:43:06 +08:00
|
|
|
git clone --recursive https://github.com/nextcloud/spreed --depth=1 --single-branch --branch "$RECORDING_VERSION" /src; \
|
2023-06-06 15:22:33 +08:00
|
|
|
mv -v /src/recording/pyproject.toml /src/recording/src/pyproject.toml; \
|
|
|
|
python3 -m pip install /src/recording/src; \
|
|
|
|
rm -rf /src; \
|
2023-06-06 18:48:43 +08:00
|
|
|
touch /etc/recording.conf; \
|
2023-06-06 16:41:19 +08:00
|
|
|
chown recording:recording -R \
|
2023-06-06 17:27:52 +08:00
|
|
|
/tmp /etc/recording.conf; \
|
2023-06-27 00:18:26 +08:00
|
|
|
mkdir -p /conf; \
|
|
|
|
chmod 777 /conf; \
|
|
|
|
chmod 777 /tmp; \
|
2023-06-06 15:22:33 +08:00
|
|
|
apk del --no-cache \
|
|
|
|
git \
|
|
|
|
wget \
|
|
|
|
shadow \
|
|
|
|
openssl;
|
|
|
|
|
2023-06-06 17:27:52 +08:00
|
|
|
WORKDIR /tmp
|
2023-06-06 15:22:33 +08:00
|
|
|
USER recording
|
|
|
|
ENTRYPOINT ["/start.sh"]
|
2023-06-27 00:18:26 +08:00
|
|
|
CMD ["python", "-m", "nextcloud.talk.recording", "--config", "/conf/recording.conf"]
|
2023-06-06 15:22:33 +08:00
|
|
|
|
|
|
|
HEALTHCHECK CMD nc -z localhost 1234 || exit 1
|
2023-06-26 06:56:08 +08:00
|
|
|
LABEL com.centurylinklabs.watchtower.enable="false"
|