diff options
| -rwxr-xr-x | server.sh | 3 |
1 files changed, 0 insertions, 3 deletions
| @@ -5,7 +5,6 @@ | |||
| 5 | # docs: | 5 | # docs: |
| 6 | # this script assumes the ip addresses is pointed to the current machine, and this script runs on 0.0.0.0 | 6 | # this script assumes the ip addresses is pointed to the current machine, and this script runs on 0.0.0.0 |
| 7 | # configuration is kinda manual cuz the official packaging is for .deb and i want rhel based system | 7 | # configuration is kinda manual cuz the official packaging is for .deb and i want rhel based system |
| 8 | # fallback (Designated Encrypted Relay for Packets) is disabled. if NAT traversal fails, there will be no connection | ||
| 9 | set -e | 8 | set -e |
| 10 | 9 | ||
| 11 | die() { echo "Error: $1" >&2; exit 1; } | 10 | die() { echo "Error: $1" >&2; exit 1; } |
| @@ -106,8 +105,6 @@ cp /var/tmp/config-example.yaml /etc/headscale/config.yaml | |||
| 106 | rm -f /var/tmp/config-example.yaml | 105 | rm -f /var/tmp/config-example.yaml |
| 107 | sed -i "s|server_url: http://127.0.0.1:8080|server_url: http://${PUBLIC_IP}:8080|" /etc/headscale/config.yaml | 106 | sed -i "s|server_url: http://127.0.0.1:8080|server_url: http://${PUBLIC_IP}:8080|" /etc/headscale/config.yaml |
| 108 | sed -i "s|listen_addr: 127.0.0.1:8080|listen_addr: 0.0.0.0:8080|" /etc/headscale/config.yaml | 107 | sed -i "s|listen_addr: 127.0.0.1:8080|listen_addr: 0.0.0.0:8080|" /etc/headscale/config.yaml |
| 109 | # Disable DERP relays — all nodes have public IPs, force direct WireGuard connections only | ||
| 110 | sed -i 's| - https://controlplane.tailscale.com/derpmap/default| # - https://controlplane.tailscale.com/derpmap/default|' /etc/headscale/config.yaml | ||
| 111 | sed -i 's| auto_update_enabled: true| auto_update_enabled: false|' /etc/headscale/config.yaml | 108 | sed -i 's| auto_update_enabled: true| auto_update_enabled: false|' /etc/headscale/config.yaml |
| 112 | chown -R headscale:headscale /etc/headscale | 109 | chown -R headscale:headscale /etc/headscale |
| 113 | 110 | ||
