Duplicate task name in role #1710
Unanswered
MarkusTeufelberger
asked this question in
New rules
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm not 100% sure if this is even a desired rule or how to check for it, but here we go:
Within at least roles, if not even whole playbooks (hard to enforce with external roles though) the
name
value of tasks and handlers should be unique. This makes the following feature work correctly:ansible-playbook playbook.yml --start-at-task="install packages"
(https://docs.ansible.com/ansible/latest/user_guide/playbooks_startnstep.html)
It also makes it easier to find a failing task directly via a search instead of having to guess which one of the "deploy configuration" or "restart service" tasks is the actual one that's being run at the moment.
Beta Was this translation helpful? Give feedback.
All reactions