mirror of
https://github.com/myvesta/vesta
synced 2025-07-06 04:51:54 -07:00
Updating update-debian8-v16-to-v17.sh, ClamAV fixes
This commit is contained in:
parent
c8d5e32c7e
commit
dfebb3fec7
1 changed files with 41 additions and 17 deletions
|
@ -63,22 +63,24 @@ fi
|
||||||
|
|
||||||
|
|
||||||
# RoundCube tinyMCE fix
|
# RoundCube tinyMCE fix
|
||||||
tinymceFixArchiveURL=$vestacp/roundcube/roundcube-tinymce.tar.gz
|
if [ "$release" -eq '8' ]; then
|
||||||
tinymceParentFolder=/usr/share/roundcube/program/js
|
tinymceFixArchiveURL=$vestacp/roundcube/roundcube-tinymce.tar.gz
|
||||||
tinymceFolder=$tinymceParentFolder/tinymce
|
tinymceParentFolder=/usr/share/roundcube/program/js
|
||||||
tinymceBadJS=$tinymceFolder/tiny_mce.js
|
tinymceFolder=$tinymceParentFolder/tinymce
|
||||||
tinymceFixArchive=$tinymceParentFolder/roundcube-tinymce.tar.gz
|
tinymceBadJS=$tinymceFolder/tiny_mce.js
|
||||||
if [[ -L "$tinymceFolder" && -d "$tinymceFolder" ]]; then
|
tinymceFixArchive=$tinymceParentFolder/roundcube-tinymce.tar.gz
|
||||||
if [ -f "$tinymceBadJS" ]; then
|
if [[ -L "$tinymceFolder" && -d "$tinymceFolder" ]]; then
|
||||||
wget $tinymceFixArchiveURL -O $tinymceFixArchive
|
if [ -f "$tinymceBadJS" ]; then
|
||||||
if [[ -f "$tinymceFixArchive" && -s "$tinymceFixArchive" ]]; then
|
wget $tinymceFixArchiveURL -O $tinymceFixArchive
|
||||||
rm $tinymceFolder
|
if [[ -f "$tinymceFixArchive" && -s "$tinymceFixArchive" ]]; then
|
||||||
tar -xzf $tinymceFixArchive -C $tinymceParentFolder
|
rm $tinymceFolder
|
||||||
rm $tinymceFixArchive
|
tar -xzf $tinymceFixArchive -C $tinymceParentFolder
|
||||||
chown -R root:root $tinymceFolder
|
rm $tinymceFixArchive
|
||||||
else
|
chown -R root:root $tinymceFolder
|
||||||
echo "File roundcube-tinymce.tar.gz is not downloaded, RoundCube tinyMCE fix is not applied"
|
else
|
||||||
rm $tinymceFixArchive
|
echo "File roundcube-tinymce.tar.gz is not downloaded, RoundCube tinyMCE fix is not applied"
|
||||||
|
rm $tinymceFixArchive
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
@ -95,12 +97,34 @@ if [ -f "$file" ] && [ $( grep -ic "NAT=''" $file ) -eq 1 ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Installing libmail-dkim-perl for better DKIM handling in Spamassassin
|
||||||
file="/etc/exim4/exim4.conf.template"
|
file="/etc/exim4/exim4.conf.template"
|
||||||
if [ -f "$file" ]; then
|
if [ -f "$file" ]; then
|
||||||
apt-get -y install libmail-dkim-perl > /dev/null 2>&1
|
apt-get -y install libmail-dkim-perl > /dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Switching to mod_remoteip
|
||||||
if [ ! -f "/etc/apache2/mods-enabled/remoteip.load" ]; then
|
if [ ! -f "/etc/apache2/mods-enabled/remoteip.load" ]; then
|
||||||
$VESTA/upd/switch_rpath.sh
|
$VESTA/upd/switch_rpath.sh
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Removing AllowSupplementaryGroups from clamav.conf
|
||||||
|
if [ -f "/etc/clamav/clamd.conf" ]; then
|
||||||
|
file="/etc/clamav/clamd.conf"
|
||||||
|
if [ $( grep -ic "# AllowSupplementaryGroups" $file ) -eq 0 ]; then
|
||||||
|
sed -i "s/AllowSupplementaryGroups/# AllowSupplementaryGroups/g" $file
|
||||||
|
service clamav-daemon restart
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Fixing /var/run/clamav permissions
|
||||||
|
if [ -f "/etc/systemd/system/multi-user.target.wants/clamav-daemon.service" ]; then
|
||||||
|
file="/etc/systemd/system/multi-user.target.wants/clamav-daemon.service"
|
||||||
|
if [ $( grep -ic "mkdir" $file ) -eq 0 ]; then
|
||||||
|
sed -i "s/\[Service\]/\[Service\]\nExecStartPre = \/bin\/mkdir -p \/var\/run\/clamav\nExecStartPre = \/bin\/chown -R clamav:clamav \/var\/run\/clamav/g" $file
|
||||||
|
service clamav-daemon restart
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue