mtproto-proxy/docker-entrypoint.sh

13 lines
319 B
Bash
Raw Normal View History

2020-04-14 16:13:56 +00:00
#!/bin/bash
set -e
if [ "$1" = "mtproto" ]; then
if [ ! -f "/data/secret" ]; then
echo "Geaerate secret ::"
head -c 16 /dev/urandom | xxd -ps | tee /data/secret
fi
exec /usr/bin/mtproto-proxy -u nobody -p 8888 -H 4443 -6 -S `cat /data/secret` --aes-pwd /proxy-secret /proxy-multi.conf -M 1
fi
exec "$@"