summaryrefslogtreecommitdiffstats
path: root/installer/opengnsys_update.sh
diff options
context:
space:
mode:
authorRamón M. Gómez <ramongomez@us.es>2019-10-01 14:04:27 +0200
committerRamón M. Gómez <ramongomez@us.es>2019-10-01 14:04:27 +0200
commit506c6708cd59e98dfad67a76f08afa83a09fdc72 (patch)
tree93779690a0014a2aa9562161a4edbcbac30593ba /installer/opengnsys_update.sh
parentcb1fbed8767ad2b49be7ea2bedb226d64babab57 (diff)
#914: Installer and updater check HTTP and HTTPS connections to avoid proxy configuration errors.
Diffstat (limited to 'installer/opengnsys_update.sh')
-rwxr-xr-xinstaller/opengnsys_update.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/installer/opengnsys_update.sh b/installer/opengnsys_update.sh
index a59e1d99..5aed44de 100755
--- a/installer/opengnsys_update.sh
+++ b/installer/opengnsys_update.sh
@@ -452,9 +452,11 @@ function checkNetworkConnection()
{
OPENGNSYS_SERVER=${OPENGNSYS_SERVER:-"opengnsys.es"}
if which curl &>/dev/null; then
- curl --connect-timeout 10 -s $OPENGNSYS_SERVER -o /dev/null
+ curl --connect-timeout 10 -s "https://$OPENGNSYS_SERVER" -o /dev/null && \
+ curl --connect-timeout 10 -s "http://$OPENGNSYS_SERVER" -o /dev/null
elif which wget &>/dev/null; then
- wget --spider -q $OPENGNSYS_SERVER
+ wget --spider -q "https://$OPENGNSYS_SERVER" && \
+ wget --spider -q "http://$OPENGNSYS_SERVER"
else
echoAndLog "${FUNCNAME}(): Cannot execute \"wget\" nor \"curl\"."
return 1