I need to run a ‘PowerShell Script Step’ (it has 10 child steps) on to 20 target servers.
I have configured a Rolling Deployment with window size as ‘5’, so expect Octopus to run ‘PS Script Step’ on 5 servers at a time, and in 4 slots.
However, I’m facing an issue as mentioned below:
When I run the ‘PS Script Step’, it runs on ‘first 5’ target servers in parallel regardless of deployment failure/success on any target server. Only after successful completion of ‘first 5’ target servers, it runs on the next '5 servers’ and so on.
However, if ‘PS Script Step’ fails on any 1 server out of ‘first 5’ servers, then step will not run on any of the remaining ‘15 servers’ and overall deployment will be marked as ‘Fail’.
I would expect ‘PS Script Step’ to run on all 20 target servers irrespective of deployment failure/success on any target server.
- ‘PS Script Step’ - whenever there is any exception or error while running the PS script, I’m using either throw “exception” or Write-Error “error” to fail the script.
- I can use ‘Octopus.Action.MaxParallelism’ variable to increase default value from ‘10’ to ‘20’ and set ‘parallel deployment’ in the Step, but it would put load on the Octopus Server. I need to increase the no. of target servers to ‘100’ or more in future so don’t want to do this.
Any help would be highly appreciated!