In this playbook:
- hosts: all
tasks:
- name: task A
debug: msg="task A"
tags:
- A
- name: task B
debug: msg="task B"
tags:
- B
- name: untagged task
debug: msg="untagged task"
I would like to run the task with the tag A and the untagged task.
I know about the --skip-tags option, but this a simplified example.
My use case is for a very complex playbook with many tags and roles with tasks with different tags, and interdependencies between tagged and non-tagged tasks. Long story short, the only 'clean' option for me is to run only specified tags and those untagged.
Is there a way to call ansible-playbook so that it'll run specific tags and untagged tasks only?
I'm using ansible 2.9.6