From b2a56c1d6a7a85f06b24bb4ea12e396bb33c940e Mon Sep 17 00:00:00 2001 From: Ark74 Date: Tue, 14 Apr 2020 11:49:11 -0500 Subject: [PATCH] Move into apt-get --- jigasi.sh | 6 +++--- jra_nextcloud.sh | 11 +++++++---- quick_jibri_installer.sh | 28 ++++++++++++++-------------- 3 files changed, 24 insertions(+), 21 deletions(-) diff --git a/jigasi.sh b/jigasi.sh index 861e583..ceb717e 100644 --- a/jigasi.sh +++ b/jigasi.sh @@ -46,8 +46,8 @@ Adding Google Cloud SDK repository for latest updates fi } install_gc_repo -apt -y update -apt -y install google-cloud-sdk google-cloud-sdk-app-engine-java +apt-get -q2 update +apt-get -y install google-cloud-sdk google-cloud-sdk-app-engine-java echo "Please select one of the current options: [1] I want to configure a new project, service account, billing and JSON credentials. @@ -162,7 +162,7 @@ sleep 2 export GOOGLE_APPLICATION_CREDENTIALS=$GC_API_JSON echo "Installing Jigasi, your SIP credentials will be asked. (mandatory)" -apt -y install jigasi +apt-get -y install jigasi cat << JIGASI_CONF >> $JIGASI_CONFIG diff --git a/jra_nextcloud.sh b/jra_nextcloud.sh index 5cc6910..b9521df 100644 --- a/jra_nextcloud.sh +++ b/jra_nextcloud.sh @@ -59,7 +59,7 @@ if [ "$(dpkg-query -W -f='${Status}' $1 2>/dev/null | grep -c "ok installed")" = echo " $1 is installed, skipping..." else echo -e "\n---- Installing $1 ----" - apt -yqq install $1 + apt-get -yq2 install $1 fi } add_mariadb() { @@ -69,7 +69,7 @@ add_mariadb() { echo "# Adding MariaDB $MDBVER repository" apt-key adv --recv-keys --keyserver keyserver.ubuntu.com C74CD1D8 echo "deb [arch=amd64] http://ftp.ddg.lth.se/mariadb/repo/$MDBVER/ubuntu $DISTRO_RELEASE main" > /etc/apt/sources.list.d/mariadb.list - apt update -qq + apt-get update -q2 fi } add_php74() { @@ -79,7 +79,7 @@ add_php74() { echo "# Adding PHP $PHPVER Repository" apt-key adv --recv-keys --keyserver keyserver.ubuntu.com E5267A6C echo "deb [arch=amd64] http://ppa.launchpad.net/ondrej/php/ubuntu $DISTRO_RELEASE main" > /etc/apt/sources.list.d/php7x.list - apt update -qq + apt-get update -q2 fi } @@ -92,7 +92,7 @@ install_ifnot mariadb-server-$MDBVER # PHP 7.4 add_php74 -apt install -y \ +apt-get install -y \ php$PHPVER-fpm \ php$PHPVER-bz2 \ php$PHPVER-curl \ @@ -365,6 +365,9 @@ sed -i "/skeletondirectory/a \ \ \'simpleSignUpLink.shown\' => false," $NC_CONFI sed -i "/simpleSignUpLink.shown/a \ \ \'knowledgebaseenabled\' => false," $NC_CONFIG sed -i "s|http://localhost|http://$NC_DOMAIN|" $NC_CONFIG +echo "Add crontab..." +crontab -u www-data -l | { cat; echo "*/5 * * * * php -f $NC_PATH/cron.php"; } | crontab -u www-data - + echo " Add memcache support... " diff --git a/quick_jibri_installer.sh b/quick_jibri_installer.sh index 2c0e007..71e466e 100644 --- a/quick_jibri_installer.sh +++ b/quick_jibri_installer.sh @@ -38,7 +38,7 @@ if [ "$(dpkg-query -W -f='${Status}' $1 2>/dev/null | grep -c "ok installed")" = echo " $1 is installed, skipping..." else echo -e "\n---- Installing $1 ----" - apt -yqq install $1 + apt-get -yq2 install $1 fi } check_serv() { @@ -84,16 +84,16 @@ update_certbot() { Cerbot repository already on the system! Checking for updates... " - apt -q2 update - apt -yq2 dist-upgrade + apt-get -q2 update + apt-get -yq2 dist-upgrade else echo " Adding cerbot (formerly letsencrypt) PPA repository for latest updates " echo "deb http://ppa.launchpad.net/certbot/certbot/ubuntu $DIST main" > /etc/apt/sources.list.d/certbot.list apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 75BCA694 - apt -qq update - apt -yqq dist-upgrade + apt-get -q2 update + apt-get -yq2 dist-upgrade fi } @@ -145,10 +145,10 @@ fi # Requirements echo "We'll start by installing system requirements this may take a while please be patient..." -apt update -yq2 -apt dist-upgrade -yq2 +apt-get update -q2 +apt-get dist-upgrade -yq2 -apt -y install \ +apt-get -y install \ bmon \ curl \ ffmpeg \ @@ -166,7 +166,7 @@ echo " # Install Jitsi Framework #-------------------------------------------------- " -apt -y install \ +apt-get -y install \ jitsi-meet \ jibri \ openjdk-8-jre-headless @@ -184,7 +184,7 @@ if [ "$(dpkg-query -W -f='${Status}' nodejs 2>/dev/null | grep -c "ok")" == "1" echo "Nodejs is installed, skipping..." else curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash - - apt install -yq2 nodejs + apt-get install -yq2 nodejs echo "Installing nodejs esprima package..." npm install -g esprima fi @@ -210,8 +210,8 @@ else wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | apt-key add - echo "deb http://dl.google.com/linux/chrome/deb/ stable main" | tee $GOOGL_REPO fi -apt -qq update -apt install -yq2 google-chrome-stable +apt-get -q2 update +apt-get install -yq2 google-chrome-stable rm -rf /etc/apt/sources.list.d/dl_google_com_linux_chrome_deb.list if [ -f /usr/local/bin/chromedriver ]; then @@ -734,8 +734,8 @@ echo " for customized support: http://switnet.net ######################################################################## " -apt -y autoremove -apt autoclean +apt-get -y autoremove +apt-get autoclean echo "Rebooting in..." secs=$((15))