Added ability to specify --WebProxy
Bryan Roe committed
Mar 10, 2021 at 12:49 UTC
881fe11960c0b883b7f148abc4509c10e3cabd3e
1 file changed
+9
-2
agents/meshinstall-linux.sh
+9
-2
@@ -54,6 +54,13 @@ CheckInstallAgent() {
54
uninstall=$1
55
url=$2
56
meshid=$3
57
+ if [[ $4 =~ ^--WebProxy= ]];
58
+ then
59
+ webproxy=$4
60
+ fi
61
+
62
+
63
+
64
meshidlen=${#meshid}
65
if [ $meshidlen -gt 63 ]
66
then
@@ -61,7 +68,7 @@ CheckInstallAgent() {
68
machinetype=$( uname -m )
69
70
# If we have 3 arguments...
64
- if [ $# -ge 4 ]
71
+ if [ $# -ge 4 ] && [ -z "$webproxy" ]
72
then
73
# echo "Computer type is specified..."
74
machineid=$4
@@ -164,7 +171,7 @@ DownloadAgent() {
171
else
172
# Install the agent
173
UpdateMshFile
167
- ./meshagent -fullinstall --copy-msh=1
174
+ ./meshagent -fullinstall --copy-msh=1 $webproxy
175
fi
176
else
177
echo "Unable to download device group settings at: $url/meshsettings?id=$meshid."