On Thu, 23 Jul 2020 10:37:38 -0700 (PDT)
Gerry Maddock <[email protected]> wrote:

> can I place the tag information be placed in the group_vars?

No. It's not possible. Quoting from "Tags"
https://docs.ansible.com/ansible/latest/user_guide/playbooks_tags.html#tags

  "You can see which tasks will be executed with --tags or --skip-tags by
  combining it with --list-tasks:

  ansible-playbook example.yml --tags "configuration,packages" --list-tasks

The tags are evaluated when a playbook starts. Otherwise the control flow
could be changed on the fly by such variables. Tags can be set

  * on the command line "--tags, --skip-tags"
  * in configuration settings in tags section "run, skip"
  * in environment "ANSIBLE_RUN_TAGS, ANSIBLE_SKIP_TAGS"

See
https://docs.ansible.com/ansible/latest/reference_appendices/config.html#tags-run
https://docs.ansible.com/ansible/latest/reference_appendices/config.html#tags-skip

Next option to consolidate tags is the concept of Ansible runner's project
https://ansible-runner.readthedocs.io/en/latest/intro.html#env-cmdline


-- 
Vladimir Botka

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/20200723213454.256801f6%40gmail.com.

Attachment: pgpLbapc7BkPC.pgp
Description: OpenPGP digital signature

Reply via email to