1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
| mkdir -p /root/tmp tar --strip-components=1 -C /root/tmp -xvf 安装包 mv -f /root/tmp/frps /usr/local/bin/azi
cat > /etc/systemd/system/azi.service <<EOF [Unit] Description = azi server After = network.target syslog.target Wants = network.target
[Service] Type = simple ExecStart = /usr/local/bin/azi -c /usr/local/etc/azi/config.toml Restart=on-failure RestartSec=5
[Install] WantedBy = multi-user.target EOF
systemctl enable azi
mkdir -p /usr/local/etc/azi/
cat > /usr/local/etc/azi/config.toml <<EOF bindPort = 8848 bindAddr = "::" auth.token = "hentailolicon" EOF
rm -r /root/tmp
|