I think if you set 'become' then you don't need to use sudo.
Also, why don't you use the module to install packages instead of executing
yum?
http://docs.ansible.com/ansible/latest/modules/yum_module.html

Example:

- name: install one specific version of Apache
  yum:
    name: httpd-2.2.29-1.4.amzn1
    state: present

On Tue, May 22, 2018, 05:35 Brian Coca <[email protected]> wrote:

> You seem to have a non standard/old sudo, change the default
> become_flags as they seem to be causing the problem, specifically,
> remove -n (default: '-H -S -n'
> )
>
> --
> ----------
> Brian Coca
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/CACVha7dTfoP38R2wh8itmi1OsyV9-8wrOO686FYjLbNZ%3DEFJ9Q%40mail.gmail.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAFGRPVr5DsZP_NrSwR7rZ0EL3y1dLh4XdKQ6j9FgnQiH5wRjeQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to