From 15659c3d28549a1165b9628f0094b5b6ccc2439a Mon Sep 17 00:00:00 2001 From: Your Name Date: Thu, 29 Jul 2021 01:52:03 +0200 Subject: [PATCH] Insatller REDIS_PREFIX --- installer/ga_install.sh | 0 installer/ga_install_prereq.sh | 0 installer/ga_setup.sh | 8 +++++++- installer/install.sh | 4 ++-- installer/laravel-echo-server-install.sh | 0 installer/october_install_prereq.sh | 0 installer/october_setup.sh | 0 7 files changed, 9 insertions(+), 3 deletions(-) mode change 100644 => 100755 installer/ga_install.sh mode change 100644 => 100755 installer/ga_install_prereq.sh mode change 100644 => 100755 installer/ga_setup.sh mode change 100644 => 100755 installer/install.sh mode change 100644 => 100755 installer/laravel-echo-server-install.sh mode change 100644 => 100755 installer/october_install_prereq.sh mode change 100644 => 100755 installer/october_setup.sh diff --git a/installer/ga_install.sh b/installer/ga_install.sh old mode 100644 new mode 100755 diff --git a/installer/ga_install_prereq.sh b/installer/ga_install_prereq.sh old mode 100644 new mode 100755 diff --git a/installer/ga_setup.sh b/installer/ga_setup.sh old mode 100644 new mode 100755 index 47d0aec..f3cc871 --- a/installer/ga_setup.sh +++ b/installer/ga_setup.sh @@ -6,11 +6,17 @@ cd /var/www/ga whiptail --msgbox "Configuring broadcaster and lighthouse" 7 44 cp .env .env.bak -awk '/BROADCAST_DRIVER/{sub(/=.*/, "=redis"); print "LIGHTHOUSE_BROADCASTER=echo"; print "LIGHTHOUSE_CACHE_TTL=200"}{print $0}' .env > "$tmp" && mv "$tmp" .env +awk '/BROADCAST_DRIVER/{sub(/=.*/, "=redis"); print $0; print "LIGHTHOUSE_BROADCASTER=echo"; print "LIGHTHOUSE_CACHE_TTL=200"; next}{print $0}' .env > "$tmp" && mv "$tmp" .env if [ $? != 0 ]; then echo -e "\033[0;31mCould not set GermanAirlines specific env variables" exit 1 fi +awk '/REDIS_PORT=*/{print $0; print "REDIS_PREFIX="; next}{print $0}' .env > "$tmp" && mv "$tmp" .env +if [ $? != 0 ]; then + echo -e "\033[0;31mCould not set GermanAirlines specific env variables" + exit 1 +fi + cd config diff --git a/installer/install.sh b/installer/install.sh old mode 100644 new mode 100755 index 37699db..a5dd44e --- a/installer/install.sh +++ b/installer/install.sh @@ -1,8 +1,8 @@ #!/bin/bash if [ "$(id -u)" != 0 ]; then - echo -e "\033[0;31mThis script must be run with root privileges" - exit 1 + echo -e "\033[0;31mThis script must be run with root privileges" + exit 1 fi ./october_install_prereq.sh diff --git a/installer/laravel-echo-server-install.sh b/installer/laravel-echo-server-install.sh old mode 100644 new mode 100755 diff --git a/installer/october_install_prereq.sh b/installer/october_install_prereq.sh old mode 100644 new mode 100755 diff --git a/installer/october_setup.sh b/installer/october_setup.sh old mode 100644 new mode 100755