diff --git a/lets-encrypt/activate-ssl.sh b/lets-encrypt/activate-ssl.sh index 0d3f28fc..573b584f 100644 --- a/lets-encrypt/activate-ssl.sh +++ b/lets-encrypt/activate-ssl.sh @@ -79,15 +79,6 @@ then fi done -# Check if port is open with NMAP -sed -i "s|127.0.1.1.*|127.0.1.1 $domain nextcloud|g" /etc/hosts -network_ok -check_open_port 80 "$domain" -check_open_port 443 "$domain" - -# Fetch latest version of test-new-config.sh -check_command download_le_script test-new-config - # Check if $domain exists and is reachable echo print_text_in_color "$ICyan" "Checking if $domain exists and is reachable..." @@ -100,6 +91,15 @@ it to this server before you can run this script." exit 1 fi +# Check if port is open with NMAP +sed -i "s|127.0.1.1.*|127.0.1.1 $domain nextcloud|g" /etc/hosts +network_ok +check_open_port 80 "$domain" +check_open_port 443 "$domain" + +# Fetch latest version of test-new-config.sh +check_command download_le_script test-new-config + # Install certbot (Let's Encrypt) install_certbot