Highly-opinionated (ex-bullshit-free) MTPROTO proxy for Telegram. If you use v1.0 or upgrade broke you proxy, please read the chapter Version 2
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

12345678910111213141516171819202122232425262728293031323334353637
  1. ###############################################################################
  2. # BUILD STAGE
  3. FROM golang:1.11-alpine
  4. RUN set -x \
  5. && apk --no-cache --update add \
  6. bash \
  7. ca-certificates \
  8. curl \
  9. git \
  10. make \
  11. upx \
  12. && update-ca-certificates
  13. COPY . /go/src/github.com/9seconds/mtg/
  14. RUN set -x \
  15. && cd /go/src/github.com/9seconds/mtg \
  16. && make -j 4 static \
  17. && upx --ultra-brute -qq ./mtg
  18. ###############################################################################
  19. # PACKAGE STAGE
  20. FROM scratch
  21. ENTRYPOINT ["/usr/local/bin/mtg"]
  22. ENV MTG_IP=0.0.0.0 \
  23. MTG_PORT=3128 \
  24. MTG_STATS_IP=0.0.0.0 \
  25. MTG_STATS_PORT=3129
  26. EXPOSE 3128 3129
  27. COPY --from=0 /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
  28. COPY --from=0 /go/src/github.com/9seconds/mtg/mtg /usr/local/bin/mtg