Run step on any 1 deployment target in role

Hi,

Octopus v2018.7.5

As part of our deployment process we have a step which runs a PowerShell script to perform some smoke tests on the artefacts we have just deployed.

We currently have a single server setup for this which has the role “SmokeTest” and the step is scoped to execute on “Deployment targets” in role “SmokeTest”. However, due to deployment mutex settings only 1 smoke test runs at a time.

We are considering adding a 2nd “SmokeTest” deployment target to increase throughput. However, we need to ensure that the step is only ran once (e.g. any one machine with role SmokeTest) and not on all deployment targets with role SmokeTest.

Is there any way we can setup this configuration?

Many thanks

Hi!

Thanks for getting in touch!

You should be able to do this by using Worker from a Worker pool. Basically instead of adding the SmokeTest machines as deployment target, add them as a worker in a worker pool, you could then configure your step to run once on a worker (see screenshot below). Workers is a new feature that we introduced from 2018.7.0, you could find more information from here

I hope this helps! Let me know what you think and how you go.

Regards
Eddy

Hi Eddy,

Many thanks for your reply.

Unfortunately I don’t think that Workers/Worker Pools are going to help in our situation.

Firstly, we are only licensed for 1 worker :slight_smile: , secondly I can’t see any way to scope a worker or pool to a particular environment or tenant.

Many thanks

Hi Dan

Scoping worker/worker pool is a feature we are working on, alternatively you could just scope the step to a specific environment as screenshot below

Our current Standard license has unlimit worker and pools, are you in a grandfather license and is there any reason from switching? Try to contact our sale team and see what they can do for licensing issues.

Otherwise, you could try adding a scope for each test server e.g. SmokeTest1, SmokeTest2. You can then scope the step to either one of them, the downside is you would need to change every project so that the workload can be distributed evenly.

I hope this helps!

Let me know how you go.

Regards
Eddy

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.