Update StackMonkey.ps1
This commit is contained in:
@@ -126,26 +126,12 @@ $Global:DattoWebhookUrl = 'https://automate.svstools.ca/webhook/svsmspkit'
|
||||
'Datto' {
|
||||
Write-LogHelper "Headless DattoRMM deploy (via n8n)" Info Startup
|
||||
|
||||
# 1) fetch creds from n8n
|
||||
$creds = Get-DattoApiCredentials -Password $N8nPassword
|
||||
if (-not $creds) {
|
||||
throw "Failed to retrieve Datto API credentials from n8n"
|
||||
}
|
||||
# need to get the info from N8N, so run the try command from line 415 to line 424
|
||||
# line 415 - 424 would get th url key and secret from n8n
|
||||
|
||||
# need to run the external cmdlet "install-dattoRMM with all variables from ParameterSetName='Datto'"
|
||||
|
||||
# 2) call the existing cmdlet from your module
|
||||
# (make sure you've already done Import-Module SVSMSP or the module that contains it)
|
||||
# line 415 - 424 would get th url key and secret from n8n
|
||||
Install-DattoRMM `
|
||||
-ApiUrl $creds.ApiUrl `
|
||||
-ApiKey $creds.ApiKey `
|
||||
-ApiSecretKey $creds.ApiSecretKey `
|
||||
-SiteUID $SiteUID `
|
||||
-SiteName $SiteName `
|
||||
-PushSiteVars:$PushSiteVars `
|
||||
-InstallRMM:$InstallRMM `
|
||||
-SaveCopy:$SaveCopy
|
||||
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user