diff --git a/Install-AteraAgent.ps1 b/Install-AteraAgent.ps1 index fb07a7c..e16f13f 100644 --- a/Install-AteraAgent.ps1 +++ b/Install-AteraAgent.ps1 @@ -1,10 +1,13 @@ param( [Parameter(Mandatory=$false)][int]$CUSTOMER_ID=1, - [Parameter(Mandatory=$false)][string]$INTEGRATOR_ID="someone@example.com", + [Parameter(Mandatory=$false)][string]$INTEGRATOR_ID, [Parameter(Mandatory=$false)][string]$AGENT_FILENAME="AteraAgentSetup.msi", [Parameter(Mandatory=$false)][switch]$FORCE ) +# Make sure $INTEGRATOR_ID exists, otherwise exit this script as an agent cannot be downloaded +If ( -not $INTEGRATOR_ID ) { Exit } + # Source the Tools.ps1 script Function SourceTools { . $([Scriptblock]::Create((New-Object Net.WebClient).DownloadString('https://dev.emberkom.com/emberkom/management-scripts/raw/branch/master/Tools.ps1'))) }