Is there any particular reason you have to ssh to localhost? Ansible will work fine if you specify connection=local in inventory.
In this case it does look like you're missing the private key (or at least ansible can't find it). Make sure you can ssh [email protected] before you run ansible. kind regards Pshem On Sun, 19 Nov 2017 at 05:29 Raresticks <[email protected]> wrote: > I've been told by a DevOps guru that Ansible needs to communicate over SSH > with the localhost, on the server side of course. > > Ok. so I've added the <ansible> account to the sudoers configurtion so > that it may authenticate without a password during runtime. > > Now, when I try to SSH to localhost it fails with this message ---> > > *Permission denied (publickey,gssapi-keyex,gssapi-with-mic)*In fact NO > account can SSH to localhost. System is Centos7 and Ansible 2.4.1.0 > > Is there any workaround for communication to localhost over SSH for > Ansible to run smoothly? If not, why is this failing? > > -- > 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/844f4cd2-a5a0-4157-a29f-e96de1812d85%40googlegroups.com > <https://groups.google.com/d/msgid/ansible-project/844f4cd2-a5a0-4157-a29f-e96de1812d85%40googlegroups.com?utm_medium=email&utm_source=footer> > . > 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/CAEaZiRVXdXnVONEQqFjAd8Q0fJ4mJe%2Bx_NNYVLuxtkvozs2vEw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
