Browse Source

Merge branch 'dev'

dev
Dnomd343 2 years ago
parent
commit
1cab9d531c
  1. 16
      Dockerfile

16
Dockerfile

@ -38,16 +38,18 @@ RUN env CGO_ENABLED=0 go build -v -trimpath -ldflags "-X main.VersionString=${DN
COPY --from=upx /tmp/upx /usr/bin/
RUN upx -9 /tmp/dnsproxy
FROM ${RUST} AS cleardns
RUN apk add build-base cmake
COPY ./ /ClearDNS/
WORKDIR /ClearDNS/src/to-json/
FROM ${RUST} AS to-json
COPY ./src/to-json/ /to-json/
WORKDIR /to-json/
RUN cargo build --release
WORKDIR /ClearDNS/bin/
FROM ${ALPINE} AS cleardns
RUN apk add build-base cmake
COPY ./ /cleardns/
COPY --from=to-json /to-json/ /cleardns/src/to-json/
WORKDIR /cleardns/bin/
RUN cmake -DCMAKE_EXE_LINKER_FLAGS=-static -DCMAKE_BUILD_TYPE=Release .. && make
RUN strip cleardns && mv cleardns /tmp/
COPY --from=upx /tmp/upx /usr/bin/
RUN upx -9 /tmp/cleardns
FROM ${ALPINE} AS build
RUN apk add xz

Loading…
Cancel
Save