Skip to content

Commit

Permalink
testing
Browse files Browse the repository at this point in the history
Some random fixes after testing.
  • Loading branch information
QROkes committed Feb 1, 2025
1 parent 3cc0ce8 commit e534837
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/bkp
Original file line number Diff line number Diff line change
Expand Up @@ -664,7 +664,7 @@ export_server() {
[[ -f /opt/webinoly/templates/source/custom_header_http_webinoly.data ]] && local include="$include /opt/webinoly/templates/source/custom_header_http_webinoly.data"
[[ -f /opt/webinoly/templates/source/custom_header_https_webinoly.data ]] && local include="$include /opt/webinoly/templates/source/custom_header_https_webinoly.data"
[[ -f /opt/webinoly/templates/source/custom_header_html_webinoly.data ]] && local include="$include /opt/webinoly/templates/source/custom_header_html_webinoly.data"
[[ -f $MYSQL_CONF_PATH/${MYSQL_CONF_PREF}-webinoly-login.cnf ]] && local include="$include $MYSQL_CONF_PATH/${MYSQL_CONF_PREF}-webinoly.cnf"
[[ -f $MYSQL_CONF_PATH/${MYSQL_CONF_PREF}-webinoly-login.cnf ]] && local include="$include $MYSQL_CONF_PATH/${MYSQL_CONF_PREF}-webinoly-login.cnf"
[[ -f $MYSQL_CONF_PATH/${MYSQL_CONF_PREF}-webinoly.cnf ]] && local include="$include $MYSQL_CONF_PATH/${MYSQL_CONF_PREF}-webinoly.cnf"
[[ -d /etc/nginx/certs ]] && local include="$include /etc/nginx/certs"

Expand Down
3 changes: 2 additions & 1 deletion lib/general
Original file line number Diff line number Diff line change
Expand Up @@ -839,7 +839,8 @@ is_domain() {
echo "false"

# Check Total Lenght
elif [[ ${#1} -gt 255 ]]; then
# Each element of a domain name separated by [.] is called a “label.” The maximum length of each label is 63 characters, and a full domain name can have a maximum of 253 characters. Alphanumeric characters and hyphens can be used in labels, but a domain name must not commence or end with a hyphen.
elif [[ ${#1} -gt 253 ]]; then
echo "false"

# Can not start or end with a hyphen
Expand Down
2 changes: 1 addition & 1 deletion lib/sites
Original file line number Diff line number Diff line change
Expand Up @@ -748,7 +748,7 @@ createsite() {
exit 1
fi
if [[ $(is_domain $domain_name) != "true" ]]; then
echo "${red}[ERROR] Domain names can only contain letters, numbers or a hyphen; can not start or end with a hyphen or period or having two periods together, and can be up to 67 characters long.${end}"
echo "${red}[ERROR] Domain names can only contain letters, numbers or a hyphen; can not start or end with a hyphen or period or having two periods together. The maximum length of each label is 63 characters, and a full domain name can have a maximum of 253 characters.${end}"
exit 1
fi

Expand Down
3 changes: 3 additions & 0 deletions lib/webin
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,9 @@ change_tools_port() {
sudo cp -rp /var/www/$ADMIN_TOOLS_SITE/* /var/www/$NEW_ADMIN_TOOLS_SITE
sudo rm -rf /var/www/$ADMIN_TOOLS_SITE

sudo chown -R www-data:www-data /var/www
[[ $(conf_read login-www-data) == "true" ]] && sudo chown root:root /var/www

sudo mv /etc/nginx/sites-available/$ADMIN_TOOLS_SITE /etc/nginx/sites-available/$NEW_ADMIN_TOOLS_SITE
sudo rm /etc/nginx/sites-enabled/$ADMIN_TOOLS_SITE
sudo ln -s /etc/nginx/sites-available/$NEW_ADMIN_TOOLS_SITE /etc/nginx/sites-enabled/$NEW_ADMIN_TOOLS_SITE
Expand Down
1 change: 0 additions & 1 deletion usr/webinoly
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,6 @@ elif [[ -n $datadog ]]; then


elif [[ -n $db_import ]]; then
check_for_mysql
database_import
nginx_not="true" # Nginx-Reload not-needed.

Expand Down

0 comments on commit e534837

Please sign in to comment.