Browse Source

Install acl package in upgrade and installation scripts.

Raphael Schneeberger 6 years ago
parent
commit
a11304d1d4
3 changed files with 10 additions and 4 deletions
  1. 2 2
      install/hst-install-debian.sh
  2. 1 1
      install/hst-install-ubuntu.sh
  3. 7 1
      install/upgrade/0.10.0-190430.sh

+ 2 - 2
install/hst-install-debian.sh

@@ -38,7 +38,7 @@ if [ "$release" -eq 8 ]; then
         flex whois rssh git idn zip sudo bc ftp lsof ntpdate rrdtool quota
         e2fslibs bsdutils e2fsprogs curl imagemagick fail2ban dnsutils
         bsdmainutils cron hestia hestia-nginx hestia-php expect libmail-dkim-perl
-        unrar-free vim-common"
+        unrar-free vim-common acl"
 else
     software="nginx apache2 apache2-utils apache2-suexec-custom
         libapache2-mod-ruid2 libapache2-mod-fcgid libapache2-mod-php php
@@ -50,7 +50,7 @@ else
         flex whois rssh git idn zip sudo bc ftp lsof ntpdate rrdtool quota
         e2fslibs bsdutils e2fsprogs curl imagemagick fail2ban dnsutils
         bsdmainutils cron hestia hestia-nginx hestia-php expect libmail-dkim-perl
-        unrar-free vim-common"
+        unrar-free vim-common acl"
 fi
 
 # Defining help function

+ 1 - 1
install/hst-install-ubuntu.sh

@@ -36,7 +36,7 @@ software="apache2 apache2.2-common apache2-suexec-custom apache2-utils
     ntpdate php php-cgi php-common php-curl phpmyadmin php-mysql php-imap php-ldap
     php-apcu phppgadmin php-pgsql postgresql postgresql-contrib proftpd-basic quota
     roundcube-core roundcube-mysql roundcube-plugins rrdtool rssh spamassassin
-    sudo hestia hestia-nginx hestia-php vim-common vsftpd whois zip"
+    sudo hestia hestia-nginx hestia-php vim-common vsftpd whois zip acl"
 
 # Defining help function
 help() {

+ 7 - 1
install/upgrade/0.10.0-190430.sh

@@ -173,6 +173,13 @@ if [ -d "/etc/roundcube" ]; then
     chown root:www-data /etc/roundcube/debian-db*
 fi
 
+# Check if acl package is installed
+if [ ! -e '/usr/bin/setfacl' ]; then
+    echo "(*) Install acl package and hardening user permissions..."
+    apt-get -qq update > /dev/null 2>&1
+    apt-get -qq -y install acl > /dev/null 2>&1
+fi
+
 # Add a general group for normal users created by Hestia
 if [ -z "$(grep ^hestia-users: /etc/group)" ]; then
     groupadd "hestia-users"
@@ -189,7 +196,6 @@ for user in `ls /usr/local/hestia/data/users/`; do
         for ftp_user in $(cat /etc/passwd | grep -v "^$user:" | grep "^$user.*:$uid:$uid:" | cut -d ":" -f1); do
             usermod -a -G "hestia-users" "$ftp_user"
         done
-
     fi
     setfacl -m "g:hestia-users:---" "$HOMEDIR/$user"
 done