# Yumrepo is not being located in ansible 2.1 using Ansible Tower

**URL:** <https://forum.ansible.com/t/yumrepo-is-not-being-located-in-ansible-2-1-using-ansible-tower/20937>\
**Category:** Ansible Project\
**Tags:** awx\
**Created:** [March 20, 2016, 8:22pm UTC](https://forum.ansible.com/t/yumrepo-is-not-being-located-in-ansible-2-1-using-ansible-tower/20937 "2016-03-20T20:22:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aaron\_Axisa](https://avatars.discourse-cdn.com/v4/letter/a/9dc877/32.png) [@Aaron\_Axisa](https://forum.ansible.com/u/Aaron_Axisa)\
**Post date:** [March 20, 2016, 8:22pm UTC](https://forum.ansible.com/t/yumrepo-is-not-being-located-in-ansible-2-1-using-ansible-tower/20937/1 "2016-03-20T20:22:13Z")

</div>

I am trying to use yumrepo [https://docs.ansible.com/ansible/yumrepo\_module.html](https://docs.ansible.com/ansible/yumrepo_module.html)  
and it states that it is new in version 2.1

So i went ahead and updated ansible on my ansible tower machine:

`

sudo yum -y install git asciidoc rpm-build python2-devel  
cd ~  
git clone git://github.com/ansible/ansible.git --recursive  
cd ansible

make rpm

sudo yum -y install rpm-build/ansible-2.1.0-0.git201603201549.6824f3a.devel.el7.centos.noarch.rpm

`

So now when I run ansible --version I get the following:

`

ansible 2.1.0  
config file = /etc/ansible/ansible.cfg  
configured module search path = Default w/o overrides

`

Now when I try to run my playbook (particularly this command in my role) :

`

```auto

- name: Add GOsa2 Repo
  yumrepo:
    name: GOsa Repository
    baseurl: http://oss.gonicus.de/pub/gosa/redhat
    gpgcheck: no
    enabled: yes

```

`

Ansible Tower 2.4.4 complains with the following error:

`  
Using /etc/ansible/ansible.cfg as config file SSH password: SUDO password[defaults to SSH password]: ERROR! no action detected in task. This often indicates a misspelled module name, or incorrect module path. The error appears to have been in ‘/var/lib/awx/projects/\_8\_\_my\_repo/ansible/roles/gosa/tasks/main.yml’: line 17, column 3, but may be elsewhere in the file depending on the exact syntax problem. The offending line appears to be: - name : Add GOsa2 Repo ^ here The error appears to have been in ‘/var/lib/awx/projects/\_8\_\_my\_repo/ansible/roles/gosa/tasks/main.yml’: line 17, column 3, but may be elsewhere in the file depending on the exact syntax problem. The offending line appears to be: - name : Add GOsa2 Repo ^ here

`

Can anyone help me with this as I don’t have any clue why it’s not detecting yumrepo at this point.

---

<div class="post-metadata">

**Author:** ![Uditha\_Desilva](https://avatars.discourse-cdn.com/v4/letter/u/f475e1/32.png) [@Uditha\_Desilva](https://forum.ansible.com/u/Uditha_Desilva)\
**Post date:** [March 21, 2016, 9:41am UTC](https://forum.ansible.com/t/yumrepo-is-not-being-located-in-ansible-2-1-using-ansible-tower/20937/2 "2016-03-21T09:41:47Z")

</div>

Tower isn’t using that version of Ansible, I believe it is still using Ansible 2.0 (or possibly earlier). I don’t think using arbitrary versions of Ansible is supported with Tower.

---

<div class="post-metadata">

**Author:** ![sivel](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/sivel/32/1198_2.png) [@sivel](https://forum.ansible.com/u/sivel)\
**Post date:** [March 21, 2016, 1:07pm UTC](https://forum.ansible.com/t/yumrepo-is-not-being-located-in-ansible-2-1-using-ansible-tower/20937/3 "2016-03-21T13:07:52Z")

</div>

yumrepo was renamed to yum\_repository somewhat recently.

You will need to use yum\_repository instead. My guess is the docs haven’t been updated yet.
