FROM alpine as builder RUN apk add --no-cache \ build-base \ git RUN git clone --depth=1 https://github.com/rofl0r/microsocks \ && cd microsocks \ && make LDFLAGS="-static -s -w" FROM alpine RUN apk add --no-cache tini COPY --from=builder /microsocks/microsocks /usr/local/bin/microsocks ENTRYPOINT ["tini", "--", "microsocks"]