In Azure git, I am running some self-hosted agents which live in the pool called "Default".
In an Azure pipeline (.yml file) I can tell the job that it has to run in a specific agent like this
pool:
name: Default
demands:
- Agent.Name -equals MACHINE1
But what if I have, for example, 4 machines and I want it to run on machine 1 or 2 but not on machine 3 or 4?
I would have thought it would look something like this:
pool:
name: Default
demands:
- Agent.Name -equals MACHINE1 -or MACHINE2
or maybe a wildcard:
pool:
name: Default
demands:
- Agent.Name -equals MACHINE*
but neither of those work. Is there a way to do this?