add Dockerfile

This commit is contained in:
Dmitry Belyaev 2023-02-28 20:29:23 +03:00
parent f902d467ea
commit 281a87c662
1 changed files with 20 additions and 0 deletions

20
Dockerfile Normal file
View File

@ -0,0 +1,20 @@
FROM rust:1-alpine as build
# sys deps
RUN apk add --no-cache musl-dev libc-dev
# cache index
RUN cargo search doh-proxy
RUN cargo install doh-proxy --no-default-features
# -----------
FROM busybox:1-musl
COPY --from=build /usr/local/cargo/bin/doh-proxy /usr/local/bin/doh-proxy
EXPOSE 3000/tcp
CMD ["doh-proxy"]