本站支持「有偿」远程协助!

Hysteria 节点搭建

消耗 大量 带宽, 网越烂, 提速效果越明显.

caddy2

apt install -y debian-keyring debian-archive-keyring apt-transport-https
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo tee /etc/apt/trusted.gpg.d/caddy-stable.asc
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list
apt update
apt install caddy

Caddyfile

hy.none.blue {
    respond "hello"
}
wget -O /usr/local/bin/hysteria https://github.com/HyNetwork/hysteria/releases/download/v0.8.6/hysteria-notun-linux-amd64
chmod +x /usr/local/bin/hysteria
sysctl -w net.core.rmem_max=4000000
cat <<EOF > /etc/systemd/system/hysteria.service
[Unit]
Description=The hysteria Proxy Serve
After=network-online.target

[Service]
ExecStart=/usr/local/bin/hysteria --log-level panic -c /etc/hysteria/config.json server
ExecStop=/bin/kill -s QUIT $MAINPID
Restart=always
RestartSec=15s

[Install]
WantedBy=multi-user.target
EOF
systemctl daemon-reload
systemctl enable hysteria
cat <<EOF > /etc/hysteria/config.json
{
  "listen": ":4567",
  "cert": "/root/.local/share/caddy/certificates/acme-v02.api.letsencrypt.org-directory/none.blue/none.blue.crt",
  "key": "/root/.local/share/caddy/certificates/acme-v02.api.letsencrypt.org-directory/none.blue/none.blue.key",
  "obfs": "7894s"
}
EOF
systemctl stop hysteria
systemctl start hysteria
#systemctl status hysteria
rm -rf /run/log/journal/*
Loading ...
无广告!