summaryrefslogtreecommitdiff
path: root/www/nginx-ultimate-bad-bot-blocker/files/patch-install-ngxblocker
diff options
context:
space:
mode:
Diffstat (limited to 'www/nginx-ultimate-bad-bot-blocker/files/patch-install-ngxblocker')
-rw-r--r--www/nginx-ultimate-bad-bot-blocker/files/patch-install-ngxblocker30
1 files changed, 30 insertions, 0 deletions
diff --git a/www/nginx-ultimate-bad-bot-blocker/files/patch-install-ngxblocker b/www/nginx-ultimate-bad-bot-blocker/files/patch-install-ngxblocker
new file mode 100644
index 000000000000..b1cf3fc19b70
--- /dev/null
+++ b/www/nginx-ultimate-bad-bot-blocker/files/patch-install-ngxblocker
@@ -0,0 +1,30 @@
+--- install-ngxblocker
++++ install-ngxblocker
+@@ -36,6 +36,7 @@ CONF_DIR=/etc/nginx/conf.d
+ BOTS_DIR=/etc/nginx/bots.d
+ SCRIPT_DIR=/usr/local/sbin
+ REPO=https://raw.githubusercontent.com/mitchellkrogza/nginx-ultimate-bad-bot-blocker/master
++SKIP_SCRIPTS=true
+
+ ####### end user configuration ##########################
+ OS=$(uname -s)
+@@ -341,11 +342,15 @@ main() {
+ check_config $CONF_DIR $BOTS_DIR $SCRIPT_DIR
+ download_files conf.d $CONF_DIR $CONF_FILES
+ download_files bots.d $BOTS_DIR $BOT_FILES
+- download_files / $SCRIPT_DIR $SCRIPT_FILES
++ if [ "$SKIP_SCRIPTS" = "false" ]; then
++ download_files / $SCRIPT_DIR $SCRIPT_FILES
+
+- # ensures scripts are executable
+- if [ "$DRY_RUN" = "N" ]; then
+- set_mode 700 $SCRIPT_DIR $SCRIPT_FILES
++ # ensures scripts are executable
++ if [ "$DRY_RUN" = "N" ]; then
++ set_mode 700 $SCRIPT_DIR $SCRIPT_FILES
++ fi
++ else
++ printf "\n** FreeBSD specific ** | not updating scripts, please use the package management for this.\n\n"
+ fi
+ }
+