added no proxy command line option

This commit is contained in:
2021-09-15 14:42:05 +02:00
parent 3a9dd52098
commit 9e8a2a3e0c
3 changed files with 6 additions and 1 deletions

View File

@@ -106,7 +106,7 @@ load_configuration
process_commandline_and_vars
# Declare proxy system vars if needed and if not already declared
if [[ -n $PROXYSRV && -n $PROXYSRVPORT ]]; then
if [[ -n $PROXYSRV && -n $PROXYSRVPORT && -z $NO_PROXY ]]; then
export http_proxy=${http_proxy:-"http://$PROXYSRV:$PROXYSRVPORT/"}
export https_proxy=${https_proxy:-"http://$PROXYSRV:$PROXYSRVPORT/"}
fi

View File

@@ -33,6 +33,8 @@ Options :
-k, --keep-going Continue l'execution en cas d'erreur.
-r, --resume Reprend l'execution là ou elle s'est arrêté.
-R, --no-root-check Ne pas vérifier les droits root (ou UID 0)
-P, --no-proxy Ne pas utiliser de proxy lors de l'utilisation de
ce script (n'empêche pas leur configuration via modules)
-h, --help Affiche ce texte d'aide.
-l, --logfile <nom> Nom du fichier de log. Peut aussi être changé
via la variable d'environnement LOGFILE.

View File

@@ -59,6 +59,9 @@ read_commandline()
"-R"|"--no-root-check")
export NO_ROOT_CHECK=true
;;
"-P"|"--no-proxy")
export NO_PROXY=true
;;
"-l"|"--logfile")
local want_logfile=true
;;