Skip to content

Commit d745459

Browse files
committed
Update installers for hestia global config in /etc
1 parent a3df2a8 commit d745459

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

install/hst-install-debian.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -949,6 +949,12 @@ mkdir -p /etc/sudoers.d
949949
cp -f $HESTIA_INSTALL_DIR/sudo/admin /etc/sudoers.d/
950950
chmod 440 /etc/sudoers.d/admin
951951

952+
# Add Hestia global config
953+
if [[ ! -e /etc/hestiacp/hestia.conf ]]; then
954+
mkdir -p /etc/hestiacp
955+
echo -e "# Do not edit this file, will get overwritten on next upgrade, use /etc/hestiacp/local.conf instead\n\nexport HESTIA='/usr/local/hestia'\n\n[[ -f /etc/hestiacp/local.conf ]] && source /etc/hestiacp/local.conf" > /etc/hestiacp/hestia.conf
956+
fi
957+
952958
# Configuring system env
953959
echo "export HESTIA='$HESTIA'" > /etc/profile.d/hestia.sh
954960
echo 'PATH=$PATH:'$HESTIA'/bin' >> /etc/profile.d/hestia.sh

install/hst-install-ubuntu.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1006,6 +1006,12 @@ mkdir -p /etc/sudoers.d
10061006
cp -f $HESTIA_INSTALL_DIR/sudo/admin /etc/sudoers.d/
10071007
chmod 440 /etc/sudoers.d/admin
10081008

1009+
# Add Hestia global config
1010+
if [[ ! -e /etc/hestiacp/hestia.conf ]]; then
1011+
mkdir -p /etc/hestiacp
1012+
echo -e "# Do not edit this file, will get overwritten on next upgrade, use /etc/hestiacp/local.conf instead\n\nexport HESTIA='/usr/local/hestia'\n\n[[ -f /etc/hestiacp/local.conf ]] && source /etc/hestiacp/local.conf" > /etc/hestiacp/hestia.conf
1013+
fi
1014+
10091015
# Configuring system env
10101016
echo "export HESTIA='$HESTIA'" > /etc/profile.d/hestia.sh
10111017
echo 'PATH=$PATH:'$HESTIA'/bin' >> /etc/profile.d/hestia.sh

0 commit comments

Comments
 (0)