Dockerfile
This commit is contained in:
parent
0ca78be006
commit
239dca0488
|
@ -1,6 +1,8 @@
|
||||||
FROM alpine:3.17
|
FROM alpine:3.17
|
||||||
LABEL maintainer "Andre Peters <andre.peters@servercow.de>"
|
LABEL maintainer "Andre Peters <andre.peters@servercow.de>"
|
||||||
|
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
ENV XTABLES_LIBDIR /usr/lib/xtables
|
ENV XTABLES_LIBDIR /usr/lib/xtables
|
||||||
ENV PYTHON_IPTABLES_XTABLES_VERSION 12
|
ENV PYTHON_IPTABLES_XTABLES_VERSION 12
|
||||||
ENV IPTABLES_LIBDIR /usr/lib
|
ENV IPTABLES_LIBDIR /usr/lib
|
||||||
|
@ -14,10 +16,13 @@ RUN apk add --virtual .build-deps \
|
||||||
iptables \
|
iptables \
|
||||||
ip6tables \
|
ip6tables \
|
||||||
xtables-addons \
|
xtables-addons \
|
||||||
|
nftables \
|
||||||
tzdata \
|
tzdata \
|
||||||
py3-pip \
|
py3-pip \
|
||||||
|
py3-nftables \
|
||||||
musl-dev \
|
musl-dev \
|
||||||
&& pip3 install --ignore-installed --upgrade pip \
|
&& pip3 install --ignore-installed --upgrade pip \
|
||||||
|
jsonschema \
|
||||||
python-iptables \
|
python-iptables \
|
||||||
redis \
|
redis \
|
||||||
ipaddress \
|
ipaddress \
|
||||||
|
@ -26,5 +31,9 @@ RUN apk add --virtual .build-deps \
|
||||||
|
|
||||||
# && pip3 install --upgrade pip python-iptables==0.13.0 redis ipaddress dnspython \
|
# && pip3 install --upgrade pip python-iptables==0.13.0 redis ipaddress dnspython \
|
||||||
|
|
||||||
COPY server.py /
|
COPY server.py /app/
|
||||||
CMD ["python3", "-u", "/server.py"]
|
COPY ./netfilter.sh /app/
|
||||||
|
|
||||||
|
RUN chmod +x /app/netfilter.sh
|
||||||
|
|
||||||
|
CMD ["/bin/sh", "-c", "/app/netfilter.sh"]
|
||||||
|
|
Loading…
Reference in New Issue