High performance Erlang MTProto proxy that powers https://t.me/socksy_bot https://t.me/erlang_mtproxy
Find a file
Сергей Прохоров a31589f40c
Fix metric bug
2018-06-08 23:43:30 +02:00
src Fix metric bug 2018-06-08 23:43:30 +02:00
.gitignore Initial implementation 2018-05-30 11:01:57 +02:00
LICENSE.txt Initial implementation 2018-05-30 11:01:57 +02:00
README.md Fix timeout state switch 2018-05-30 11:27:09 +02:00
rebar.config Implement sponsored channels and work through official endpoints 2018-06-08 23:36:38 +02:00
rebar.lock Implement sponsored channels and work through official endpoints 2018-06-08 23:36:38 +02:00
rebar3 Initial implementation 2018-05-30 11:01:57 +02:00

Erlang mtproto proxy

This part of code was extracted from @socksy_bot.

How to start

Install deps (ubuntu 18.04)

sudo apt install erlang-nox erlang-dev build-essential

Compile:

./rebar3 release

Start with interactive console:

./_build/default/rel/mtp_proxy/bin/mtp_proxy console

Start in foreground

./_build/default/rel/mtp_proxy/bin/mtp_proxy foreground

Start in background

./_build/default/rel/mtp_proxy/bin/mtp_proxy start

Stop proxy started in background

./_build/default/rel/mtp_proxy/bin/mtp_proxy stop

Settings

See src/mtproto_proxy.app.src.

Secret key will be printed on start.

Helpers

Number of connections in background mode

./_build/default/rel/mtp_proxy/bin/mtp_proxy eval 'lists:sum([proplists:get_value(all_connections, L) || {_, L} <- ranch:info()]).'