Why am I Getting "the term '<command_name>' is not recognized as the name of a cmdlet, function, script file, or operable program" when Running a Command on a Windows Managed Host using Ansible?
Issue
When running a command on a Windows managed node, for example using the win_shell module, I'm getting the below error for the command.
Example for puppet command.
"error": "The term 'puppet' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.",
Environment
Ansible Engine
Ansible Tower
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.