2024-08-23 06:15:39 +02:00
|
|
|
# Pull from small Debian stable image.
|
|
|
|
FROM alpine:latest
|
|
|
|
LABEL maintainer="dselen@nerthus.nl"
|
2024-08-24 13:45:13 +02:00
|
|
|
ENV PYTHONPATH="/usr/lib/python3.12/site-packages"
|
2024-08-23 06:15:39 +02:00
|
|
|
|
2024-08-23 23:49:54 +02:00
|
|
|
WORKDIR /opt/wireguarddashboard/src
|
2024-08-23 06:15:39 +02:00
|
|
|
RUN apk update && \
|
2024-08-24 13:45:13 +02:00
|
|
|
apk add --no-cache sudo gcc musl-dev linux-headers && \
|
2024-08-23 06:15:39 +02:00
|
|
|
apk add --no-cache wireguard-tools && \
|
2024-08-24 13:45:13 +02:00
|
|
|
apk add --no-cache iptables ip6tables && \
|
2024-08-23 23:49:54 +02:00
|
|
|
mkdir /opt/wireguarddashboard/src/master-key
|
2024-08-23 06:15:39 +02:00
|
|
|
|
2024-08-24 13:45:13 +02:00
|
|
|
|
2024-08-23 23:49:54 +02:00
|
|
|
COPY ./src /opt/wireguarddashboard/src/
|
2024-08-24 13:45:13 +02:00
|
|
|
COPY ./docker/alpine/entrypoint.sh /opt/wireguarddashboard/src/
|
|
|
|
#COPY ./docker/alpine/wgd.sh /opt/wireguarddashboard/src/
|
|
|
|
#COPY ./docker/alpine/requirements.txt /opt/wireguarddashboard/src/
|
2024-08-23 06:15:39 +02:00
|
|
|
|
2024-08-23 23:49:54 +02:00
|
|
|
RUN chmod u+x /opt/wireguarddashboard/src/entrypoint.sh
|
2024-08-23 06:15:39 +02:00
|
|
|
|
|
|
|
|
|
|
|
# Defining a way for Docker to check the health of the container. In this case: checking the login URL.
|
|
|
|
HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 CMD curl -f http://localhost:10086/signin || exit 1
|
|
|
|
|
2024-08-23 23:49:54 +02:00
|
|
|
ENTRYPOINT ["/opt/wireguarddashboard/src/entrypoint.sh"]
|