Skip to content

自建 derper

103 字小于 1 分钟

2024-12-01

//https://tailscale.com/download/linux/ubuntu-2204


curl -fsSL https://pkgs.tailscale.com/stable/ubuntu/jammy.noarmor.gpg | sudo tee /usr/share/keyrings/tailscale-archive-keyring.gpg >/dev/null
curl -fsSL https://pkgs.tailscale.com/stable/ubuntu/jammy.tailscale-keyring.list | sudo tee /etc/apt/sources.list.d/tailscale.list


sudo apt-get update
sudo apt-get install tailscale

tailscale up --login-server=https://xxxx.com --accept-routes=true --accept-dns=false

安装golang

wget https://go.dev/dl/go1.23.1.linux-amd64.tar.gz
rm -rf /usr/local/go && tar -C /usr/local -xzf go1.23.1.linux-amd64.tar.gz

vim .bashrc

export PATH=$PATH:/usr/local/go/bin

安装 derper

go env -w GOPROXY=https://goproxy.cn,direct
go install tailscale.com/cmd/derper@main

nohup /root/go/bin/derper -c /root/derper/derper.conf -hostname derp-nb-1.hylab.space -certmode letsencrypt -verify-clients &