--- - name: "[OpenRC] Restart service: named (to deploy config changes)" service: name: named state: restarted when: - ansible_service_mgr == "openrc" listen: "Restart bind" - name: "[systemd] Restart service: named (to deploy config changes)" systemd: name: named state: restarted when: - ansible_service_mgr == "systemd" listen: "Restart bind"