File tree Expand file tree Collapse file tree 4 files changed +14
-3
lines changed
Expand file tree Collapse file tree 4 files changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -110,7 +110,7 @@ function syshealth_update_user_config_format() {
110110}
111111
112112# Update list of known keys for db.conf files
113- function syshealth_update_database_config_format () {
113+ function syshealth_update_db_config_format () {
114114
115115 # DATABASE CONFIGURATION
116116 # Create array of known keys in configuration file
@@ -139,8 +139,7 @@ function syshealth_repair_web_config() {
139139 sanitize_config_file
140140 get_domain_values ' web'
141141 prev=" DOMAIN"
142- for key in $known_keys ;
143- do
142+ for key in $known_keys ; do
144143 if [ -z " ${! key} " ]; then
145144 add_object_key ' web' ' DOMAIN' " $domain " " $key " " $prev "
146145 fi
Original file line number Diff line number Diff line change @@ -624,6 +624,16 @@ upgrade_rebuild_users() {
624624 fi
625625}
626626
627+ upgrade_replace_default_config () {
628+ if [ " $UPGRADE_REPLACE_KNOWN_KEYS " ]; then
629+ syshealth_update_web_config_format
630+ syshealth_update_mail_config_format
631+ syshealth_update_dns_config_format
632+ syshealth_update_db_config_format
633+ syshealth_update_user_config_format
634+ fi
635+ }
636+
627637upgrade_restart_services () {
628638 if [ " $UPGRADE_RESTART_SERVICES " = " true" ]; then
629639 echo " [ * ] Restarting services..."
Original file line number Diff line number Diff line change @@ -41,6 +41,7 @@ UPGRADE_UPDATE_FILEMANAGER='true'
4141UPGRADE_UPDATE_FILEMANAGER_CONFIG='false'
4242
4343# Post installation clean-up
44+ UPGRADE_REPLACE_KNOWN_KEYS='true'
4445UPGRADE_REBUILD_USERS='true'
4546UPGRADE_RESTART_SERVICES='true'
4647
Original file line number Diff line number Diff line change @@ -42,6 +42,7 @@ upgrade_welcome_message
4242
4343# Perform upgrade health check and refresh configuration before upgrading
4444upgrade_health_check | tee -a $LOG
45+ upgrade_replace_default_config
4546upgrade_refresh_config
4647
4748# Back up existing configuration files and templates
You can’t perform that action at this time.
0 commit comments