Calling a script from another PSU node from API in HA mode

I’ve deployed several PSU nodes in HA mode behind a load balancer. The HA feature is wonderful, thanks for adding it! I have PSU scripts that I call from different API endpoints. Each nod is in its own AD domain (no trusts between them). I’d like to run specific scripts on specific PSU nodes.

From the web UI I can specific on which PSU node a script runs:

I can programmatically run a script using Invoke-PSUScript -Name "RunMe1.ps1" -ComputerName xxx -AppToken yyy
Is there a better way to do this? I’d rather not have to store an app token in my secret store if I don’t have to.


Product: PowerShell Universal
Version: 4.0.7

Answer from Support, posting here for others with the same question:

You can use the -Queue parameter to specify the computer or queue name to run the script on. It is the same value that is passed when running it in the admin console’s Run On parameter.

1 Like