[Update] Disable Solr when upgrading from non-Solr mailcows

This commit is contained in:
andryyy
2019-01-19 22:00:18 +01:00
parent 4235d8a1d1
commit 54a14c01aa

View File

@@ -222,6 +222,12 @@ for option in ${CONFIG_ARRAY[@]}; do
echo '# Solr will refuse to start with total system memory below or equal to 2 GB.' >> mailcow.conf
echo "SOLR_HEAP=1024" >> mailcow.conf
fi
elif [[ ${option} == "SKIP_SOLR" ]]; then
if ! grep -q ${option} mailcow.conf; then
echo "Adding new option \"${option}\" to mailcow.conf"
echo '# Solr is disabled by default after upgrading from non-Solr to Solr-enabled mailcows.' >> mailcow.conf
echo "SKIP_SOLR=y" >> mailcow.conf
fi
elif ! grep -q ${option} mailcow.conf; then
echo "Adding new option \"${option}\" to mailcow.conf"
echo "${option}=n" >> mailcow.conf