guard to exit script if agent is installed
This commit is contained in:
@@ -1,5 +1,11 @@
|
|||||||
# NOTE: The $CONFIG variable must be set by the calling script
|
# NOTE: The $CONFIG variable must be set by the calling script
|
||||||
|
|
||||||
|
# Exit this script if agent is already installed
|
||||||
|
If ( Test-Path "${Env:ProgramFiles}\ESET\RemoteAdministrator\Agent\ERAAgent.exe" ) {
|
||||||
|
Microsoft.Powershell.Utility\Write-Output "ESET agent is already installed. This script will now exit."
|
||||||
|
Return
|
||||||
|
}
|
||||||
|
|
||||||
# Set path to temp directory
|
# Set path to temp directory
|
||||||
$TEMPDIR = '{0}eset-protect-deployment' -f (Get-TempPath)
|
$TEMPDIR = '{0}eset-protect-deployment' -f (Get-TempPath)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user