ansible -m ping -i hosts test1 -vvv
Hosts file have a simple configuration
[test]
test1 ansible_host=remote_host ansible_user=remote_user ansible_private_key_file=/var/jenkins_home/ansible/id_rsa
jenkins@0bde7f6019a2:~/ansible$ ssh -i id_rsa remote_user@remote_host
Enter passphrase for key 'id_rsa':
Last login: Fri Jul 5 12:10:51 2019 from jenkins.jenkins_net
test1 | UNREACHABLE! => {
"changed": false,
"msg": "Failed to connect to the host via ssh: Control socket connect(/var/jenkins_home/.ansible/cp/45a4bb8b49): Connection refused\r\nFailed to connect to new control master",
"unreachable": true
}
Any help will or advice be appreciated.
Best regards,
--
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 ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/41557231-d666-4af9-9c1c-aedfc54fd0b9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi,Run docker command with --net=host.Thanks.
On Sun, Jul 7, 2019, 00:00 Claudio Rivas <clsr...@gmail.com> wrote:
Hi,--I'm trying to connect to remote host through SSH and a Private Key to run a simple test to start working with Ansible to generate my inventories:ansible -m ping -i hosts test1 -vvv
Hosts file have a simple configuration
[test]
test1 ansible_host=remote_host ansible_user=remote_user ansible_private_key_file=/var/jenkins_home/ansible/id_rsa
SSH is working fine to connect to remote server with this key:jenkins@0bde7f6019a2:~/ansible$ ssh -i id_rsa remote_user@remote_host
Enter passphrase for key 'id_rsa':
Last login: Fri Jul 5 12:10:51 2019 from jenkins.jenkins_net
While trying to do the connection with ansible seems to have problems I can't find or troubleshoot, the error indicates:test1 | UNREACHABLE! => {
"changed": false,
"msg": "Failed to connect to the host via ssh: Control socket connect(/var/jenkins_home/.ansible/cp/45a4bb8b49): Connection refused\r\nFailed to connect to new control master",
"unreachable": true
}
Any help will or advice be appreciated.
Best regards,
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 ansible...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/400d32d7-b25c-4888-b276-4d4ba348b7f4%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CAAcjD-XS6OVe3f5LLvSLpQ%2BMBtriMdRA%2BuAFWK28bUJ-UEXM3A%40mail.gmail.com.
Thank you, yes I have generated the key with a password, but didn’t configured it for the Ansible connection, now I’m searching how to do it, but if you have an example will be helpful.
Thank you again
--
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 ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/3652f9bc-591e-4dfb-9495-ded73dadfb8a%40googlegroups.com.
Same container.
Generating the certificate without passwords makes problems with ssh server.
--
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 ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/10028eaf-9c2a-4bbd-8976-c9b84d48430b%40googlegroups.com.
test1 | UNREACHABLE! => {
"changed": false,
"msg": "Failed to connect to the host via ssh: percent_expand: unknown key %(",
"unreachable": true
}
--
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 ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/64dca2a9-04be-4d39-8b6c-49a908bf2f46%40googlegroups.com.