Last active
November 28, 2018 07:39
-
-
Save gengen1988/a0cf77983c50ccab811e00d951faa7fa to your computer and use it in GitHub Desktop.
install shadowsocks on server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
apt-get update | |
apt-get install -y docker.io docker-compose | |
apt-get install -y linux-image-4.15.0-39-lowlatency linux-modules-4.15.0-39-lowlatency | |
echo "tcp_bbr" >> /etc/modules-load.d/modules.conf | |
echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf | |
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf | |
echo "net.ipv4.tcp_fastopen=3" >> /etc/sysctl.conf | |
cat > docker-compose.yaml << EOF | |
version: "3" | |
services: | |
shadowsocks: | |
image: shadowsocks/shadowsocks-libev | |
ports: | |
- 3389:3389/tcp | |
- 3389:3389/udp | |
environment: | |
- SERVER_PORT=3389 | |
- PASSWORD=WEV4CjCs79NsPGeP | |
- METHOD=xchacha20-ietf-poly1305 | |
restart: always | |
EOF | |
reboot |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment