From 565f36e0565a8346076bed87bf6a321177649aac Mon Sep 17 00:00:00 2001 From: usmannasir Date: Thu, 19 Jun 2025 00:48:21 +0500 Subject: [PATCH] bug fix: onboarding --- .../baseTemplate/custom-js/system-status.js | 15 +- .../templates/baseTemplate/onboarding.html | 602 +++++++++++++++--- 2 files changed, 511 insertions(+), 106 deletions(-) diff --git a/baseTemplate/static/baseTemplate/custom-js/system-status.js b/baseTemplate/static/baseTemplate/custom-js/system-status.js index 664e2b20d..db947a0e3 100644 --- a/baseTemplate/static/baseTemplate/custom-js/system-status.js +++ b/baseTemplate/static/baseTemplate/custom-js/system-status.js @@ -748,7 +748,8 @@ app.controller('OnboardingCP', function ($scope, $http, $timeout, $window) { $scope.ExecutionStatus = true; $scope.ReportStatus = true; $scope.OnboardineDone = true; - + + var statusTimer = null; function statusFunc() { $scope.cyberpanelLoading = false; @@ -774,18 +775,24 @@ app.controller('OnboardingCP', function ($scope, $http, $timeout, $window) { $scope.functionStatus = response.data.currentStatus; $scope.cyberpanelLoading = true; $scope.OnboardineDone = false; - $timeout.cancel(); + if (statusTimer) { + $timeout.cancel(statusTimer); + statusTimer = null; + } } else { $scope.functionProgress = {"width": response.data.installationProgress + "%"}; $scope.functionStatus = response.data.currentStatus; - timeout(statusFunc, 3000); + statusTimer = $timeout(statusFunc, 3000); } } else { $scope.cyberpanelLoading = true; $scope.functionStatus = response.data.error_message; $scope.functionProgress = {"width": response.data.installationProgress + "%"}; - $timeout.cancel(); + if (statusTimer) { + $timeout.cancel(statusTimer); + statusTimer = null; + } } } diff --git a/baseTemplate/templates/baseTemplate/onboarding.html b/baseTemplate/templates/baseTemplate/onboarding.html index 4a3f5c4a2..b2ac7fd0a 100644 --- a/baseTemplate/templates/baseTemplate/onboarding.html +++ b/baseTemplate/templates/baseTemplate/onboarding.html @@ -1,115 +1,513 @@ {% extends "baseTemplate/index.html" %} {% load i18n %} {% block title %}{% trans "Configure Hostname and other default Settings - CyberPanel" %}{% endblock %} + +{% block header_scripts %} + +{% endblock %} + {% block content %} +{% load static %} +{% get_current_language as LANGUAGE_CODE %} - {% load static %} - {% get_current_language as LANGUAGE_CODE %} - - - -
-
-

{% trans "Initial Configurations" %}- {% trans "Learn More" %}

+
+
+ + - -
-
-

- {% trans "Initial Configurations" %} -

-
- -
-
-
    -
  • Choose this wisely, if you are not going to use email service on this server, skip rDNS checks. Ensure that the hostname you provide below is set as rDNS (reverse DNS, also called PTR record) against your - IP address. (Only required if you want to use email services on the same server) -
  • -
  • Make sure that the provided hostname also has an A record pointing to your server's - IP address. -
  • -
  • If the above conditions fail, your server may not function as expected, especially - for email services. -
  • -
- -
- -
- -
- -
-
- -
- -
-
- -
-
-
- -
- -
- - -
-
- - -
- -
- - -
-
- - - - -
- - + + +
+

+ {% trans "Server Configuration" %} + +

+ + +
+
+ +

{% trans "Important Configuration Notes" %}

- -
-
-
-

Note: once configurations are completed, click Restart CyberPanel above, after clicking Restart CyberPanel refresh page to fetch new SSL from the browser.

-

{$ functionStatus $} -

-
-
-
-
+
    +
  • + {% trans "Choose wisely" %}: {% trans "If you are not going to use email service on this server, skip rDNS checks." %} +
  • +
  • + {% trans "Ensure that the hostname you provide below is set as rDNS (reverse DNS, also called PTR record) against your IP address. (Only required if you want to use email services on the same server)" %} +
  • +
  • + {% trans "Make sure that the provided hostname also has an A record pointing to your server's IP address." %} +
  • +
  • + {% trans "If the above conditions fail, your server may not function as expected, especially for email services." %} +
  • +
+
+ + +
+
+ + +
+ +
+ +
+ +
-
+
+ +
+ + + +
+ +
+ + +
+
+ +

{% trans "Note: Once configurations are completed, click Restart CyberPanel above. After clicking Restart CyberPanel, refresh the page to fetch new SSL from the browser." %}

+
+ +
+ {$ functionStatus $} + +
+ +
+
- -
- - +
{% endblock %}