Skip to content

Instantly share code, notes, and snippets.

@anvodev
Created May 29, 2025 12:10
Show Gist options
  • Save anvodev/43637996aa96dfb9badb68c3ce25cfe2 to your computer and use it in GitHub Desktop.
Save anvodev/43637996aa96dfb9badb68c3ce25cfe2 to your computer and use it in GitHub Desktop.
Telegram proxy docker makefile
IMAGE_NAME = telegrammessenger/proxy:latest
CONTAINER_NAME = mtproto-proxy
PORT = 443
SECRET = secret # ← Replace this or override via `make run SECRET=...`
run:
docker run -d \
--name $(CONTAINER_NAME) \
-p $(PORT):443 \
-p 8888:8888 \
-e SECRET=$(SECRET) \
-e STATS_PORT=8888 \
-e AD_TAG=00000000000000000000000000000000 \
--ulimit nofile=65536:65536 \
--restart always \
--privileged \
$(IMAGE_NAME)
stop:
docker stop $(CONTAINER_NAME)
rm:
docker rm $(CONTAINER_NAME)
logs:
docker logs -f $(CONTAINER_NAME)
restart:
make stop || true
make rm || true
make run
sh:
docker exec -it $(CONTAINER_NAME) sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment