Is this the correct method if root login is disabled?
Fayad Sent from my OnePlus One On 04-Aug-2017 12:19 PM, "Fayad" <[email protected]> wrote: > Hi, > > Yes, I've already enabled it. Please see the below lines: > > [privilege_escalation] > become=True > become_method=sudo > become_user=root > become_ask_pass=False > > Fayad > > On Fri, Jul 28, 2017 at 11:55 PM, Kai Stian Olstad < > [email protected]> wrote: > >> On 28. juli 2017 17:12, Fayad wrote: >> >>> I've added the following line in the /etc/sudoers file on the client >>> server: >>> >>> ansible_user ALL=(root) NOPASSWD: ALL >>> >>> Won't this provide enough privilege for the ansible user to execute >>> commands as root? >>> >> >> Yes, it will, but you still has to tell ansible to use become, it won't >> magically use sudo unless you specify become: true or use the option -b on >> the command line. >> >> -- >> Kai Stian Olstad >> >> -- >> 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/ms >> gid/ansible-project/e7a63a07-8c7c-fe33-71ca-73e6a799d748%40olstad.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/CAFFLvzdkj1R_wmHsrKe_YNOqmmG-YdE6gcaC5uXnS9sFjYFMTQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
