参考这篇:https://teddysun.com/536.html
# 创建配置文件 - 下次重启可用
PASSWORD="!!!!!!改成你自己的密码!!!!!!" && \
mkdir -p /data/ss; cd /data/ss; \
cat > config.json <<EOF
{
"server":"0.0.0.0",
"server_port":9000,
"password":"${PASSWORD}",
"timeout":500,
"method":"aes-256-gcm",
"fast_open":false,
"nameserver":"8.8.8.8",
"mode":"tcp_and_udp"
}
EOF
# 开启docker - 使用了本机22端口 - 这个比较清奇,不过你想用啥端口都行
docker stop ss; docker rm ss; \
docker run -d -p 22:9000 -p 22:9000/udp \
--name ss --restart=always \
-v /data/ss:/etc/shadowsocks-libev \
teddysun/shadowsocks-libev && \
docker logs -f ss

如果使用simple-obfs插件的话
{
"server":"0.0.0.0",
"server_port":9000,
"password":"password0",
"timeout":300,
"method":"aes-256-gcm",
"fast_open":true,
"nameserver":"8.8.8.8",
"mode":"tcp_and_udp",
"plugin":"obfs-server",
"plugin_opts":"obfs=tls"
}
如果开启 v2ray-plugin的话
{
"server":"0.0.0.0",
"server_port":9000,
"password":"password0",
"timeout":300,
"method":"aes-256-gcm",
"fast_open":true,
"nameserver":"8.8.8.8",
"mode":"tcp_and_udp",
"plugin":"v2ray-plugin",
"plugin_opts":"server"
}
然后建立ucloud上面的globalssh,就可以利用免费2M带宽的22口端口进行内网不过墙的iplc转发了。


