I'm setting up a small project in ansible, with a shared node with other projects. This node is the CI runner, and should rarely be the target of a playbook.
I want to exclude a group from all by default
The current solution that I have is just to have a group called bystanders, and exclude it from all playbooks that run all
hosts:
[groupA]
node1
[bystanders]
ci-node
playbook_example:
hosts: all:!bystanders
...
But this is prone to error, or forgetting to exclude that in some playbook, inadvertently running a playbook on that node.