Merge pull request #4532 from nextcloud/enh/noid/bp-logic

nextcloud - add logic for BRUTEFORCE_PROTECTION
This commit is contained in:
Simon L 2024-04-11 20:26:47 +02:00 committed by GitHub
commit 52cdc7fe68
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -498,6 +498,14 @@ php /var/www/html/occ maintenance:update:htaccess
# Revert dbpersistent setting to check if it fixes too many db connections
php /var/www/html/occ config:system:set dbpersistent --value=false --type=bool
if [ "$DISABLE_BRUTEFORCE_PROTECTION" = yes ]; then
php /var/www/html/occ config:system:set auth.bruteforce.protection.enabled --type=bool --value=false
php /var/www/html/occ config:system:set ratelimit.protection.enabled --type=bool --value=false
else
php /var/www/html/occ config:system:set auth.bruteforce.protection.enabled --type=bool --value=true
php /var/www/html/occ config:system:set ratelimit.protection.enabled --type=bool --value=true
fi
# Disallow creating local external storages when nothing was mounted
if [ -z "$NEXTCLOUD_MOUNT" ]; then
php /var/www/html/occ config:system:set files_external_allow_create_new_local --type=bool --value=false