Compare commits

...

3 Commits

3 changed files with 21 additions and 3 deletions

View File

@ -13,6 +13,7 @@ If (!(Test-Path -PathType Container $PackagePath)) {
}
Write-Host "Downloading Agent Installer..."
Invoke-WebRequest -Uri $AgentInstallUrl -OutFile $AgentInstallerPath
Invoke-WebRequest -Uri $AgentInstallUrl -OutFile $AgentInstallerPath -UseBasicParsing
Write-Host "Starting installation..."
msiexec.exe /i "$AgentInstallPath" /q /lv "$(Join-Path -Path $PackagePath -ChildPath $AgentInstallerName).log" SERVERADDRESS="$ServerAddress" SERVERPASS="$ServerPass" LOCATION="$LocationId"
msiexec.exe /i "$AgentInstallPath" /q /lv "$(Join-Path -Path $PackagePath -ChildPath $AgentInstallFile).log" SERVERADDRESS="$ServerAddress" SERVERPASS="$ServerPass" LOCATION="$LocationId"
Write-Host "Log saved at $(Join-Path -Path $PackagePath -ChildPath $AgentInstallFile).log"

17
rmm/automate/README.md Normal file
View File

@ -0,0 +1,17 @@
# Connectwise Automate Scripts
Tip: [Run these scripts through ScreenConnect](https://screenconnect.connectwise.com/blog/product-tips-and-updates/become-a-remote-support-power-user-with-screenconnect) by prepending `#!ps` on it's own line before the script.
## Install-Automate.ps1
Replace the variables below with the values applicable for your environment. The script will download the Automate agent from your Automate server, so it must be able to reach this URL.
```powershell
$ServerUrl = 'https://automate.example.com'
$ServerPass = '1CZauGNRipB4zbzZwqDanZ='
$LocationId = '123'
```
## Uninstall-Automate.ps1
Downloads the Agent uninstaller from AWS S3 and silently runs it in the background.

View File

@ -1,7 +1,7 @@
$PackagePath = 'C:\Packages'
$AgentUninstallFile = 'Agent_Uninstaller.zip'
$AgentUninstallUri = 'https://s3.amazonaws.com/assets-cp/assets/$AgentUninstallFile'
$AgentUninstallUri = "https://s3.amazonaws.com/assets-cp/assets/$AgentUninstallFile"
$AgentUninstallPath = Join-Path -Path $PackagePath -ChildPath $AgentUninstallFile
If (!(Test-Path -PathType Container $PackagePath)) {