mirror of
https://github.com/myvesta/vesta
synced 2025-08-19 21:04:07 -07:00
daemon autostart while apt-get install
This commit is contained in:
parent
c8adfe025c
commit
4b15491482
2 changed files with 22 additions and 2 deletions
|
@ -373,14 +373,24 @@ if [ "$srv_type" = 'small' ]; then
|
||||||
software=$(echo "$software" | sed -e 's/spamassassin//')
|
software=$(echo "$software" | sed -e 's/spamassassin//')
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Install Vesta packages
|
# Update system packages
|
||||||
apt-get update
|
apt-get update
|
||||||
|
|
||||||
|
# Disable daemon autostart
|
||||||
|
# For more details /usr/share/doc/sysv-rc/README.policy-rc.d.gz
|
||||||
|
echo -e '#!/bin/sh \nexit 101' > /usr/sbin/policy-rc.d
|
||||||
|
chmod a+x /usr/sbin/policy-rc.d
|
||||||
|
|
||||||
|
# Install Vesta packages
|
||||||
apt-get -y install $software
|
apt-get -y install $software
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
echo 'Error: apt-get install failed'
|
echo 'Error: apt-get install failed'
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Restore policy
|
||||||
|
rm -f /usr/sbin/policy-rc.d
|
||||||
|
|
||||||
|
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
# Configure system #
|
# Configure system #
|
||||||
|
|
|
@ -375,14 +375,24 @@ if [ "$srv_type" = 'small' ]; then
|
||||||
software=$(echo "$software" | sed -e 's/spamassassin//')
|
software=$(echo "$software" | sed -e 's/spamassassin//')
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Install Vesta packages
|
# Update system packages
|
||||||
apt-get update
|
apt-get update
|
||||||
|
|
||||||
|
# Disable daemon autostart
|
||||||
|
# For more details /usr/share/doc/sysv-rc/README.policy-rc.d.gz
|
||||||
|
echo -e '#!/bin/sh \nexit 101' > /usr/sbin/policy-rc.d
|
||||||
|
chmod a+x /usr/sbin/policy-rc.d
|
||||||
|
|
||||||
|
# Install Vesta packages
|
||||||
apt-get -y install $software
|
apt-get -y install $software
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
echo 'Error: apt-get install failed'
|
echo 'Error: apt-get install failed'
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Restore policy
|
||||||
|
rm -f /usr/sbin/policy-rc.d
|
||||||
|
|
||||||
|
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
# Configure system #
|
# Configure system #
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue