No Ansible Remote Execution on Proxy Server

Followed the instructions and doesnt work.

Main Foreman server show ansible in active features
proxy servers missing ansible in active features

I’ve run the plugin option
foreman-installer --enable-foreman-plugin-ansible --enable-foreman-proxy-plugin-ansible
ssh remote exectution working using ssh
ansible execution failing for hosts on proxy.

Expected outcome:
showing that ansible is available on proxies

Foreman and Proxy versions:
Foreman and Proxy plugin versions:
[foreman_ansible] Ansible integration with Foreman Daniel Lobato Garcia 6.1.1

Distribution and version:

Other relevant data:

is there some kind of error? Just saying “it does not work” doesn’t really give us much to go by.

And as a side note, if I recall correctly Foreman 2.3 has already reached its end of life and it would be good if you could consider upgrading to a more recent version.

Hi, error when you run the job against a proxy is
Failed to initialize: RuntimeError - Could not use any proxy. Consider configuring remote_execution_global_proxy, remote_execution_fallback_proxy in settings

As I said ssh remote execution work perfect.
I think the proxy doesnt know what to do with ansible.
The Foreman server says

The proxy server says

No errors were encountered when install the ansible-proxy plugin.
It just doesnt appear to of installed.

Oh, ok. So you have a foreman server and a separate proxy machine and you set things up by running foreman-installer --enable-foreman-plugin-ansible --enable-foreman-proxy-plugin-ansible on the foreman server?

1 Like

Yes , I have multple proxies and installed the plugin as per the command you mentioned.
is there something you need to do on the proxies ?

Yes, you need to enable the proxy plugin on each of the proxies that you want to use. Assuming you used the installer on those machines as well, the command should be just foreman-installer --enable-foreman-proxy-plugin-ansible

Fantastic. That solved it .
I didnt want to just do that as the documentation says run it on the foreman server there is no reference to enable it on proxy servers as well.
Thank you for your help

Glad to hear you got it working.

Sadly most of the plugin docs are a bit dated and incomplete. The newer docs however do mention that Configuring Foreman to use Ansible (step 1.1.2)