Score:0

loading additional modules with ansible tower

in flag

I'm trying to run a playbook on ansible tower but I'm having issues loading extra modules. I checked the playbook is configured right but it still fails with the message below...

[WARNING]: Invalid characters were found in group names but not replaced, use
-vvvv to see details
ERROR! couldn't resolve module/action 'ansible.windows.win_package'. This often indicates a misspelling, missing collection, or incorrect module path.
The error appears to be in '/tmp/bwrap_371_vfy0csh9/awx_371_vu6g6dfa/project/windows-playbook.yml': line 5, column 7, but may
be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:
    - name: Test Install
      ^ here

I might be blind but how do I get ansible tower to load these modules? I'm not sure if its a setting I've missed or extra config required in the playbook itself... Any help would really be appreciated. I'll pop in my playbook below.

---
- hosts: all

  tasks:
    - name: Test Install
      ansible.windows.win_package:
        path: \\FILESHARE\data\Software\Installer.msi
        arguments: '/q /norestart'
        state: present
Michael Hampton avatar
cz flag
What version of Ansible do you have on your Tower installation?
mitchell2423 avatar
in flag
@MichaelHampton ansible 2.9.20
Michael Hampton avatar
cz flag
That sounds like the correct version.
Score:1
cz flag

You're running Ansible 2.9, which for the most part has not adopted the new module/module collection naming scheme from 2.10 and later versions. Because these have caused a lot of confusion and some breakage, Red Hat has decided not to update Ansible past 2.9 at this time, and thus Ansible Tower also remains on 2.9.

If you check the docs, you will see that 2.9 has not done so for the ansible.windows collection, thus you should continue using the old name, win_package.

mitchell2423 avatar
in flag
That did the trick, its working now. thanks
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.