From 562ad763dd8961cd561b46e95aac5badb2475893 Mon Sep 17 00:00:00 2001 From: myvesta <38690722+myvesta@users.noreply.github.com> Date: Sun, 5 Nov 2023 15:25:01 +0100 Subject: [PATCH] v-commander: install nginx-rate-limit templates --- bin/v-commander | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/bin/v-commander b/bin/v-commander index 2ab8dc17d..28f97e840 100644 --- a/bin/v-commander +++ b/bin/v-commander @@ -78,12 +78,13 @@ myhelp() { echo "q = quit" echo "h = help" echo "-----------------------------" - echo "inst v = install myVesta" - echo "inst p = install multi-php" - echo "inst pgw = install php-gate" - echo "inst r = install new Roundcube" - echo "inst memcached = install memcached" - echo "inst redis = install Redis" + echo "inst v = install myVesta" + echo "inst p = install multi-php" + echo "inst pgw = install php-gate" + echo "inst r = install new Roundcube" + echo "inst memcached = install memcached" + echo "inst redis = install Redis" + echo "inst nginx-rate-limit = install nginx-rate-limit templates" echo "dis fb = stop and disable fail2ban" echo "dis dove = stop and disable dovecot" echo "dis spam = stop and disable spam" @@ -459,6 +460,15 @@ do echo "-------------------" fi + if [ "$answer" = 'inst nginx-rate-limit' ] || [ "$answer" = 'INST NGINX-RATE-LIMIT' ]; then + echo "=============================" + echo "== Installing inst nginx-rate-limit templates" + curl -O https://c.myvestacp.com/tools/rate-limit-tpl/install_rate_limit_tpl.sh + bash install_rate_limit_tpl.sh + echo "== nginx-rate-limit templates installed." + echo "-------------------" + fi + if [ "$answer" = 'check fc' ] || [ "$answer" = 'CHECK FC' ]; then echo "== Checking if FreshClam is up" clamavup=$(/usr/local/vesta/bin/v-list-sys-services | grep 'clamav-daemon' | grep -c 'running')