From 07b387f18518e1789985f3eb43aef2f36c57d590 Mon Sep 17 00:00:00 2001 From: Daniel Hansson Date: Tue, 3 Oct 2023 15:39:45 +0200 Subject: [PATCH] fixed wanip --- install.sh | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/install.sh b/install.sh index 45b394a..ad87c9d 100644 --- a/install.sh +++ b/install.sh @@ -1,8 +1,5 @@ #!/bin/bash -# TEEEEEEEST -sudo rm -Rf /usr/bin/hbbr /usr/bin/hbbs /var/log/rustdesk-server /var/lib/rustdesk-server - # shellcheck disable=SC2034 true # see https://github.com/koalaman/shellcheck/wiki/Directive @@ -400,7 +397,7 @@ Do you want to install Certbot with snap? (recommended)" touch "/etc/nginx/sites-available/rustdesk.conf" cat << NGINX_RUSTDESK_CONF > "/etc/nginx/sites-available/rustdesk.conf" server { - server_name ${wanip}; + server_name ${RUSTDESK_DOMAIN}; location / { proxy_set_header X-Real-IP \$remote_addr; proxy_set_header X-Forwarded-For \$proxy_add_x_forwarded_for; @@ -427,9 +424,9 @@ NGINX_RUSTDESK_CONF ufw reload # Generate the certifictae - if ! certbot --nginx --cert-name "${wanip}" --key-type ecdsa --renew-by-default --no-eff-email --agree-tos --server https://acme-v02.api.letsencrypt.org/directory -d "${wanip}" + if ! certbot --nginx --cert-name "${RUSTDESK_DOMAIN}" --key-type ecdsa --renew-by-default --no-eff-email --agree-tos --server https://acme-v02.api.letsencrypt.org/directory -d "${RUSTDESK_DOMAIN}" then - msg_box "Sorry, the TLS certificate for $wanip failed to generate! + msg_box "Sorry, the TLS certificate for $RUSTDESK_DOMAIN failed to generate! Please check that port 80/443 are correctly port forwarded, and that the DNS record points to this servers IP. Please try again."