mirror of
https://github.com/stefanpejcic/openpanel
synced 2025-06-26 18:28:26 +00:00
Update UPDATE.sh
This commit is contained in:
@@ -15,3 +15,18 @@ for dir in /home/*; do
|
||||
fi
|
||||
done
|
||||
|
||||
echo ""
|
||||
echo "Adding demo_mode option for both OpenAdmin and OpenPanel.."
|
||||
FILE="/etc/openpanel/openpanel/conf/openpanel.config"
|
||||
|
||||
# Check if dev_mode exists under the [PANEL] section
|
||||
if ! grep -q "dev_mode" "$FILE"; then
|
||||
if grep -q "\[PANEL\]" "$FILE"; then
|
||||
sed -i '/\[PANEL\]/a dev_mode=off' "$FILE"
|
||||
echo "dev_mode=off added under [PANEL]."
|
||||
else
|
||||
echo "error: PANEL section doesn't exist!"
|
||||
fi
|
||||
else
|
||||
echo "dev_mode already exists."
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user