Skip to content

Instantly share code, notes, and snippets.

@brianlan
Last active October 12, 2019 07:37
Show Gist options
  • Save brianlan/d487c8eb1a43aaaabe957f00539e8d9f to your computer and use it in GitHub Desktop.
Save brianlan/d487c8eb1a43aaaabe957f00539e8d9f to your computer and use it in GitHub Desktop.
setup my new ubuntu
exp_port=$1; shift; # port to expose
passwd=$1;
sudo apt update
sudo apt install -y vim git software-properties-common curl
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt-get update
sudo apt-get install -y docker-ce
sudo usermod -aG docker ${USER}
docker run -dt --name ssserver -p ${exp_port}:${exp_port} -p 6500:6500/udp mritd/shadowsocks -m "ss-server" -s "-s 0.0.0.0 -p ${exp_port} -m chacha20-ietf-poly1305 -k ${passwd}" -x -e "kcpserver" -k "-t 127.0.0.1:${exp_port} -l :6500 -mode fast2"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment