mirror of
https://github.com/LowderPlay/cheburcheck.git
synced 2026-08-29 05:02:09 +00:00
Some checks are pending
Build Rust Application / Linux amd64 (.deb) (push) Waiting to run
Build Rust Application / Linux arm64 (.deb via cross) (push) Waiting to run
Build Rust Application / Windows amd64 (push) Waiting to run
CodeQL Advanced / Analyze (rust) (push) Waiting to run
Build and Publish Docker Images / Build website image (push) Waiting to run
Build and Publish Docker Images / Build frontend image (push) Waiting to run
Build and Publish Docker Images / Deploy (push) Blocked by required conditions
Build Probe / Linux amd64 binary and .deb (push) Waiting to run
Build Probe / Linux arm64 binary and .deb (push) Waiting to run
Build Probe / Windows amd64 binary (push) Waiting to run
Build Probe / Docker image amd64/arm64 (push) Waiting to run
* feat: ip probe traceroute * feat: block bogon and rate limit * fix: block badge * fix: control sampling * docs: update probing info * feat: disable traceroute * feat: dns spoofing * docs: dns spoofing * chore: bump version * fix: default rate limit
32 lines
873 B
Docker
32 lines
873 B
Docker
# syntax=docker/dockerfile:1.10
|
|
|
|
FROM docker.io/rust:1-slim-bookworm AS build
|
|
|
|
WORKDIR /build
|
|
|
|
COPY . .
|
|
|
|
RUN --mount=type=cache,id=probe-target,target=/build/target \
|
|
--mount=type=cache,id=cargo-registry,target=/usr/local/cargo/registry \
|
|
--mount=type=cache,id=cargo-git,target=/usr/local/cargo/git \
|
|
set -eux; \
|
|
RUSTFLAGS="-C strip=symbols" cargo build --locked --release --package probe --bin cheburprobe; \
|
|
cp target/release/cheburprobe ./probe-bin
|
|
|
|
FROM docker.io/debian:bookworm-slim
|
|
|
|
RUN apt-get update && \
|
|
apt-get install --yes --no-install-recommends libcap2-bin && \
|
|
rm -rf /var/lib/apt/lists/* && \
|
|
groupadd --system app && \
|
|
useradd --system --gid app --home-dir /app --shell /usr/sbin/nologin app
|
|
|
|
WORKDIR /app
|
|
|
|
COPY --from=build /build/probe-bin ./probe
|
|
|
|
RUN setcap cap_net_raw=ep ./probe
|
|
|
|
USER app
|
|
|
|
ENTRYPOINT ["./probe"]
|