Skip to content

Commit

Permalink
more checks fail2ban
Browse files Browse the repository at this point in the history
  • Loading branch information
nacho committed May 26, 2017
1 parent 7196f17 commit 45ef188
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions etc/nextcloudpi-config.d/fail2ban.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,11 @@ configure()
{
[[ $ACTIVE_ != "yes" ]] && { service fail2ban stop; update-rc.d fail2ban disable; return; }

touch /var/www/nextcloud/data/nextcloud.log
chown -R www-data /var/www/nextcloud/data
local BASEDIR=$( dirname "$NCLOG_" )
[ -d $BASEDIR ] || { echo -e "directory $BASEDIR not found"; return 1; }

sudo -u www-data touch $NCLOG_ || { echo -e "ERROR: user www-data does not have write permissions on $NCLOG_"; return 1; }
chown -R www-data $BASEDIR

cd /var/www/nextcloud
sudo -u www-data php occ config:system:set loglevel --value=2
Expand Down

0 comments on commit 45ef188

Please sign in to comment.