This commit is contained in:
tuend-work
2025-11-13 11:08:42 +07:00
parent 3b52e718ca
commit 27eec3dcc6
8 changed files with 9 additions and 117 deletions

View File

@@ -478,7 +478,8 @@ ${DA_SCRIPTS}/cron_deny.sh
echo "Chạy getLicense"
getLicense
#getServices
echo "Chạy getServices"
getServices
if [ ! -e ${DA_PATH}/custombuild/options.conf ] && [ -e /etc/redhat-release ] && [ ! -e /etc/init.d/xinetd ] && [ -e /usr/bin/yum ]; then
yum -y install xinetd

View File

@@ -1731,7 +1731,7 @@ if [ $COUNT -ne 0 ]; then
fi
cd $DA_PATH;
tar xzf update.tar.gz
//tar xzf update.tar.gz
if [ ! -e $DA_PATH/directadmin ]; then
echo "Cannot find the DirectAdmin binary. Extraction failed";
@@ -1751,7 +1751,7 @@ fi
###############################################################################
# write the setup.txt
echo "Chạy write the $SETUP"
echo "hostname=$HOST" > $SETUP;
echo "email=$EMAIL" >> $SETUP;
echo "mysql=$DB_ROOT_PASS" >> $SETUP;
@@ -1782,6 +1782,8 @@ chmod 600 $SETUP
cd $SCRIPTS_PATH;
chmod 700 install.sh
echo "Chạy ./install.sh $CMD_LINE"
./install.sh $CMD_LINE
RET=$?
@@ -1812,32 +1814,6 @@ if [ -e /etc/aliases ]; then
fi
fi
#CSF if AUTO
if [ "${OS}" != "FreeBSD" ] && [ "${AUTO}" = "1" ]; then
CSF_LOG=/var/log/directadmin/csf_install.log
CSF_SH=/root/csf_install.sh
wget -O ${CSF_SH} ${SERVER}/all/csf/csf_install.sh > ${CSF_LOG} 2>&1
if [ ! -s ${CSF_SH} ]; then
echo "Error downloading ${SERVER}/all/csf/csf_install.sh"
cat ${CSF_LOG}
else
#run it
chmod 755 ${CSF_SH}
${CSF_SH} auto >> ${CSF_LOG} 2>&1
USE_IPSET=true
if [ -x /usr/bin/systemd-detect-virt ]; then
if systemd-detect-virt | grep -m1 -q -E 'lxc|openvz'; then
USE_IPSET=false
fi
fi
if ${USE_IPSET} && grep -m1 -q '^LF_IPSET = "0"' /etc/csf/csf.conf; then
perl -pi -e 's|^LF_IPSET = "0"|LF_IPSET = "1"|g' /etc/csf/csf.conf
csf -r >> /dev/null 2>&1
fi
fi
${BUILD} secure_php
fi
rm -f /usr/lib/sendmail
ln -s ../sbin/sendmail /usr/lib/sendmail