Skip to content

Commit b8a9261

Browse files
committed
Error Handling For wget Command
1 parent c82a735 commit b8a9261

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

usr/local/sbin/easyengine

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ NGINXREPO()
8080
|| OwnError "Unable To Add Nginx DotDeb Repository"
8181

8282
# Fetch And Install The GnuPG Key
83-
wget -qcO /tmp/dotdeb.gpg http://www.dotdeb.org/dotdeb.gpg || OwnError "Unable To Download DotDeb GnuPG Key"
83+
wget --no-check-certificate -cqO /tmp/dotdeb.gpg http://www.dotdeb.org/dotdeb.gpg || OwnError "Unable To Download DotDeb GnuPG Key"
8484
apt-key add /tmp/dotdeb.gpg &>> $INSTALLLOG || OwnError "Unable To Add DotDeb GnuPG Key"
8585
fi
8686
}
@@ -115,7 +115,7 @@ PHPREPO()
115115
fi
116116

117117
# Fetch And Install The GnuPG Key
118-
wget -qcO /tmp/dotdeb.gpg http://www.dotdeb.org/dotdeb.gpg || OwnError "Unable To Download DotDeb GnuPG Key"
118+
wget --no-check-certificate -cqO /tmp/dotdeb.gpg http://www.dotdeb.org/dotdeb.gpg || OwnError "Unable To Download DotDeb GnuPG Key"
119119
apt-key add /tmp/dotdeb.gpg &>> $INSTALLLOG || OwnError "Unable To Add DotDeb GnuPG Key"
120120
fi
121121
}
@@ -452,7 +452,8 @@ PHP_PACKAGES()
452452

453453
# Downloading Nginx FastCGI Cleanup Script
454454
echo -e "\033[34mDownloading Nginx FastCGI Cleanup Script, Please Wait...\e[0m"
455-
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/nginx/clean.php https://raw.githubusercontent.com/rtCamp/eeadmin/master/cache/nginx/clean.php
455+
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/nginx/clean.php https://raw.githubusercontent.com/rtCamp/eeadmin/master/cache/nginx/clean.php \
456+
|| OwnError "Unable To Download Nginx Fastcgi Cleanup Script"
456457
fi
457458

458459
# Opcache Settings
@@ -463,9 +464,9 @@ PHP_PACKAGES()
463464

464465
# Download Opcache Status Files
465466
echo -e "\033[34mInstalling Opcache Tool, Please Wait...\e[0m"
466-
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/opcache/opcache.php https://raw.github.com/rlerdorf/opcache-status/master/opcache.php
467-
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/opcache/opgui.php https://raw.github.com/amnuts/opcache-gui/master/index.php
468-
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/opcache/ocp.php https://gist.github.com/ck-on/4959032/raw/0b871b345fd6cfcd6d2be030c1f33d1ad6a475cb/ocp.php
467+
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/opcache/opcache.php https://raw.github.com/rlerdorf/opcache-status/master/opcache.php || OwnError "Unable To Download Opcache Tool opcache.php"
468+
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/opcache/opgui.php https://raw.github.com/amnuts/opcache-gui/master/index.php || OwnError "Unable To Download Opcache Tool opgui.php"
469+
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/opcache/ocp.php https://gist.github.com/ck-on/4959032/raw/0b871b345fd6cfcd6d2be030c1f33d1ad6a475cb/ocp.php || OwnError "Unable To Download Opcache Toolocp.php"
469470
fi
470471

471472
# Memcache Settings
@@ -476,7 +477,8 @@ PHP_PACKAGES()
476477

477478
# Download phpMemcachedAdmin
478479
echo -e "\033[34mInstalling Memcache Tool, Please Wait...\e[0m"
479-
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/memcache/memcache.tar.gz http://phpmemcacheadmin.googlecode.com/files/phpMemcachedAdmin-1.2.2-r262.tar.gz
480+
wget --no-check-certificate -cqO /var/www/22222/htdocs/cache/memcache/memcache.tar.gz http://phpmemcacheadmin.googlecode.com/files/phpMemcachedAdmin-1.2.2-r262.tar.gz \
481+
|| OwnError "Unable To Download Memcache Tool"
480482

481483
# Extract phpMemcachedAdmin
482484
tar -zxf /var/www/22222/htdocs/cache/memcache/memcache.tar.gz -C /var/www/22222/htdocs/cache/memcache

0 commit comments

Comments
 (0)