From cf50cb86a8d6ec6e2b3e522c5dc192ef08078ca7 Mon Sep 17 00:00:00 2001 From: Robby-Swartenbroekx Date: Wed, 17 Jun 2020 16:22:55 +0200 Subject: [PATCH 1/4] Version 5.0.2 This version adds the possibility to configure the CustomerID in the xml settings file instead of needing to pass it with the installer --- Deployment Package/AGENT/InstallAgent.ps1 | 17 +++++++++++++++-- .../AGENT/Lib/InstallAgent-Core.psm1 | 9 +++++++-- Deployment Package/AGENT/PartnerConfig.xml | 10 +++++++--- README.md | 7 ++++--- ReleaseNotes.md | 7 +++++++ 5 files changed, 40 insertions(+), 10 deletions(-) diff --git a/Deployment Package/AGENT/InstallAgent.ps1 b/Deployment Package/AGENT/InstallAgent.ps1 index 14f40b9..83e0054 100644 --- a/Deployment Package/AGENT/InstallAgent.ps1 +++ b/Deployment Package/AGENT/InstallAgent.ps1 @@ -6,6 +6,19 @@ ########## Change Log ########## ################################ +### 5.0.2 on 2020-06-17 - Robby Swartenbroekx +################################################################## +# FIXES/FEATURES +# - Script prioritizes Activation Info as follows: +# 1 - Discovered Activation Key (currently installed Agent) +# 2 - Discovered Customer/Site ID (currently installed Agent) +# 3 - Historical Activation Key (Local History File) +# 4 - Historical Customer/Site ID (Local History File) +# 5 - Default Customer ID for New Devices (GPO/Command-Line Parameter) +# 6 - Default Customer ID for New Devices (from the settings file) +# 7 - Historical Default Customer ID (Local History File, if no GPO/Command-Line Parameter is +# Present/Valid) + ### 5.0.1 on 2019-08-26 - Ryan Crowther Jr ################################################################## # FIXES/FEATURES @@ -163,7 +176,7 @@ ################################################################## param ( [Parameter(Mandatory=$true)] - $LauncherPath, + $LauncherPath = "C:\temp\AGENT", [Parameter(Mandatory=$false)] $CustomerID ) @@ -255,7 +268,7 @@ $SC = @{ } "RunningInstanceTimeout" = 30 "ScriptEventLog" = "Application" - "ScriptVersion" = "5.0.1" + "ScriptVersion" = "5.0.2" "SuccessScriptAction" = "Graceful Exit" "SuccessScriptResult" = "Script Completed Successfully" } diff --git a/Deployment Package/AGENT/Lib/InstallAgent-Core.psm1 b/Deployment Package/AGENT/Lib/InstallAgent-Core.psm1 index 32ce1cf..b7a0fde 100644 --- a/Deployment Package/AGENT/Lib/InstallAgent-Core.psm1 +++ b/Deployment Package/AGENT/Lib/InstallAgent-Core.psm1 @@ -1,6 +1,6 @@ # Core Functions for the Agent Setup Script (InstallAgent.ps1) -# Last Revised: 2019-08-26 -# Module Version: 5.0.1 +# Last Revised: 2020-06-17 +# Module Version: 5.0.2 ### INITIALIZATION FUNCTIONS ############################### @@ -615,6 +615,11 @@ function ValidatePartnerConfig ### Deployment Values $Config.LocalFolder = $Partner.Config.Deployment.LocalFolder $Config.NetworkFolder = $Partner.Config.Deployment.NetworkFolder + if ($null -eq $Script.CustomerID) + { $Script.CustomerID = + if ($Partner.Config.Deployment.CustomerID -match $NC.Validation.CustomerID) + { $Partner.Config.Deployment.CustomerID } + } # Installer Values if ($Device.OSBuild -gt "6.0") { # Use Typical (Latest) Agent diff --git a/Deployment Package/AGENT/PartnerConfig.xml b/Deployment Package/AGENT/PartnerConfig.xml index f3d1414..bf5c43f 100644 --- a/Deployment Package/AGENT/PartnerConfig.xml +++ b/Deployment Package/AGENT/PartnerConfig.xml @@ -3,9 +3,10 @@ # ABOUT # - Partner Configuration File for the InstallAgent Automation Suite # by Ryan Crowther Jr, RADCOMP Technologies - 2019-08-26 +# by Robby Swartenbroekx, b-inside bv - 2020-06-17 # - Original Configuration File (InstallAgent.ini) by Jon Czerwinski, Cohn Consulting Corp. - 2017-01-20 # Maintained by the Solarwinds MSP Community -# File Version - 5.0.1 +# File Version - 5.0.2 # USAGE Set your Configuration Values for your Deployment Package here. See the Deployment Steps section of @@ -81,6 +82,9 @@ help@mymsp.com C:\AGENT AGENT + + + @@ -97,10 +101,10 @@ help@mymsp.com WindowsAgentSetup.exe - 12.0.1.118 + 12.3.0.650 - 12.0.10118.0 + 12.3.1650.0 -My MSP -(888) MSP-4ALL -help@mymsp.com + My MSP + (888) MSP-4ALL + help@mymsp.com - + @@ -81,6 +83,12 @@ help@mymsp.com C:\AGENT AGENT + + + 102 + + + d128dc27-f21b-dba0-913c-355bf538acea @@ -90,17 +98,17 @@ help@mymsp.com 4.5.2 - 4.5.51209.34209 WindowsAgentSetup.exe - 12.0.1.118 + 2020.1.20326 - 12.0.10118.0 + 2020.1.20326.0