1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
| git clone -b stable https://github.com/alexbers/mtprotoproxy.git
pip install cryptography
nano mtprotoproxy/config.py # 设置端口 及 至少一个 USERS 中的 secret key
mv mtprotoproxy/ /usr/bin/mtprotoproxy nano /etc/systemd/system/MTProtoProxy.service
[Unit] Description=MTProtoProxy After=network.target
[Service] Type=simple User=nobody WorkingDirectory=/usr/bin/mtprotoproxy ExecStart=/bin/python3 /usr/bin/mtprotoproxy/mtprotoproxy.py Restart=always
[Install] WantedBy=multi-user.target
systemctl start MTProtoProxy systemctl enable MTProtoProxy
|