diff --git a/lib/ansible/modules/system/service_facts.py b/lib/ansible/modules/system/service_facts.py index b884daff7e2..e5e06980f3d 100644 --- a/lib/ansible/modules/system/service_facts.py +++ b/lib/ansible/modules/system/service_facts.py @@ -22,6 +22,15 @@ description: version_added: "2.5" requirements: ["Any of the following supported init systems: systemd, sysv, upstart"] +notes: + - When accessing the C(ansible_facts.services) facts collected by this module, + it is recommended to not use "dot notation" because services can have a C(-) + character in their name which would result in invalid "dot notation", such as + C(ansible_facts.services.zuul-gateway). It is instead recommended to + using the string value of the service name as the key in order to obtain + the fact data value like C(ansible_facts.services['zuul-gateway']) + + author: - Matthew Jones - Adam Miller (@maxamillion)