-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Expand file tree
/
Copy pathDockerfile
More file actions
34 lines (27 loc) · 767 Bytes
/
Dockerfile
File metadata and controls
34 lines (27 loc) · 767 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
30
31
32
33
34
FROM rust:1.88-slim AS builder
# Install build dependencies for both X11 and Wayland
RUN apt-get update && apt-get install -y \
libfreetype6-dev \
libexpat1-dev \
libpcap-dev \
libasound2-dev \
libfontconfig1-dev \
libgtk-3-dev \
pkg-config \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /usr/src/sniffnet
COPY . .
RUN cargo build --release
# Runtime stage
FROM debian:bookworm-slim
# Install runtime dependencies for both X11 and Wayland
RUN apt-get update && apt-get install -y \
libfreetype6 \
libexpat1 \
libpcap0.8 \
libasound2 \
libfontconfig1 \
libgtk-3-0 \
&& rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/src/sniffnet/target/release/sniffnet /usr/local/bin/sniffnet
ENTRYPOINT ["sniffnet"]