mirror of
https://github.com/bytedance/g3.git
synced 2026-05-04 06:30:43 +00:00
add example Dockerfile
This commit is contained in:
parent
14a7367ac0
commit
0b52602eb0
7 changed files with 73 additions and 0 deletions
14
g3proxy/docker/debian.Dockerfile
Normal file
14
g3proxy/docker/debian.Dockerfile
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
FROM rust:bookworm AS builder
|
||||
WORKDIR /usr/src/g3
|
||||
COPY . .
|
||||
RUN apt-get update && apt-get install -y libclang-dev cmake capnproto
|
||||
RUN cargo build --profile release-lto \
|
||||
--no-default-features --features vendored-boringssl,quic,vendored-c-ares,hickory \
|
||||
-p g3proxy -p g3proxy-ctl
|
||||
|
||||
FROM debian:bookworm-slim
|
||||
RUN apt-get update && apt-get install -y ca-certificates && rm -rf /var/lib/apt/lists/*
|
||||
COPY --from=builder /usr/src/g3/target/release-lto/g3proxy /usr/bin/g3proxy
|
||||
COPY --from=builder /usr/src/g3/target/release-lto/g3proxy-ctl /usr/bin/g3proxy-ctl
|
||||
ENTRYPOINT ["/usr/bin/g3proxy"]
|
||||
CMD ["-Vvv"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue