-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathDockerfile
More file actions
29 lines (24 loc) · 868 Bytes
/
Dockerfile
File metadata and controls
29 lines (24 loc) · 868 Bytes
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
# Set the base image
FROM ghcr.io/linuxserver/baseimage-alpine:3.23@sha256:f27f8149f0fafcf9c539d77d394c7f7c23646b841494f089a52a7efcf036c808
# Set the maintainer
LABEL maintainer="GhostWriters"
# copy local files
COPY root/ /
# Install required packages and application dependencies
RUN \
echo "**** install runtime packages ****" && \
apk add --no-cache \
py3-pip && \
echo "**** install app ****" && \
pip3 install --break-system-packages --no-cache-dir -r /opt/requirements.txt && \
echo "**** cleanup ****" && \
rm -rf \
/tmp/* \
"$HOME/.cache"
# Add a health check command to ensure the container is running correctly
HEALTHCHECK --interval=15m \
--timeout=3s \
CMD ps -ef | grep cron || exit 1 \
&& ping -c 1 www.packtpub.com >/dev/null 2>&1 || exit 1
# Volume where the config file and crontab
VOLUME /config