2024-09-26 17:21:01 +02:00
|
|
|
|
|
|
|
|
# Firegex Dockerfile UUID signature
|
|
|
|
|
# cf1795af-3284-4183-a888-81ad3590ad84
|
|
|
|
|
# Needed for start.py to detect the Dockerfile
|
|
|
|
|
|
|
|
|
|
|
2024-10-13 01:50:52 +02:00
|
|
|
FROM --platform=$BUILDPLATFORM oven/bun AS frontend
|
2022-08-03 13:44:30 +02:00
|
|
|
WORKDIR /app
|
|
|
|
|
ADD ./frontend/package.json .
|
2025-02-02 20:42:01 +01:00
|
|
|
ADD ./frontend/bun.lock .
|
2024-10-19 18:39:42 +02:00
|
|
|
RUN bun i
|
2022-08-03 13:44:30 +02:00
|
|
|
COPY ./frontend/ .
|
2024-04-09 02:20:51 +02:00
|
|
|
RUN bun run build
|
2022-08-03 13:44:30 +02:00
|
|
|
|
|
|
|
|
|
2022-06-12 20:02:05 +02:00
|
|
|
#Building main conteiner
|
2025-02-05 12:22:31 +01:00
|
|
|
FROM --platform=$TARGETARCH debian:trixie-slim AS base
|
2024-10-19 18:39:42 +02:00
|
|
|
RUN apt-get update -qq && apt-get upgrade -qq && \
|
2025-02-05 12:22:31 +01:00
|
|
|
apt-get install -qq python3-pip build-essential \
|
2025-02-02 20:42:01 +01:00
|
|
|
libnetfilter-queue-dev libnfnetlink-dev libmnl-dev libcap2-bin\
|
|
|
|
|
nftables libvectorscan-dev libtins-dev python3-nftables
|
2022-07-19 17:56:54 +02:00
|
|
|
|
2022-07-18 18:52:14 +02:00
|
|
|
RUN mkdir -p /execute/modules
|
2022-06-11 21:57:50 +02:00
|
|
|
WORKDIR /execute
|
|
|
|
|
|
2022-07-22 01:12:54 +02:00
|
|
|
ADD ./backend/requirements.txt /execute/requirements.txt
|
2023-06-04 20:09:06 +02:00
|
|
|
RUN pip3 install --no-cache-dir --break-system-packages -r /execute/requirements.txt --no-warn-script-location
|
2022-08-02 13:13:58 +00:00
|
|
|
|
2022-07-22 00:34:57 +02:00
|
|
|
COPY ./backend/binsrc /execute/binsrc
|
2025-02-02 19:54:42 +01:00
|
|
|
RUN g++ binsrc/nfqueue.cpp -o modules/cppqueue -O3 -lnetfilter_queue -pthread -lnfnetlink $(pkg-config --cflags --libs libtins libhs libmnl)
|
2022-07-17 10:36:14 +02:00
|
|
|
|
2022-06-28 16:02:52 +02:00
|
|
|
COPY ./backend/ /execute/
|
2023-06-05 00:55:38 +02:00
|
|
|
COPY --from=frontend /app/dist/ ./frontend/
|
2022-08-10 10:23:37 +00:00
|
|
|
|
|
|
|
|
CMD ["/bin/sh", "/execute/docker-entrypoint.sh"]
|
2022-06-12 20:02:05 +02:00
|
|
|
|
|
|
|
|
|