ansible foreman callback plugin

116 views
Skip to first unread message

Kiran Kumar

unread,
Aug 9, 2020, 8:55:48 PM8/9/20
to Ansible Project
Hi

I have setup the plugin for forman 


Also install below on ansible control node 

yum install -y python-pip
 pip install requests




the plugin file is updated 

from __future__ import absolute_import


FOREMAN_URL = os.getenv('FOREMAN_URL', "https://xxx")
# Substitute by a real SSL certificate and key if your Foreman uses HTTPS
FOREMAN_SSL_CERT = (os.getenv('FOREMAN_SSL_CERT', "/etc/foreman-proxy/ssl_cert.pem"),
                    os.getenv('FOREMAN_SSL_KEY', "/etc/foreman-proxy/ssl_key.pem"))



Ansible side is updated 

[callback_foreman]



ssl_cert = /etc/foreman-proxy/ssl_cert.pem
ssl_key = /etc/foreman-proxy/ssl_key.pem
verify_certs = /etc/foreman-proxy/ssl_ca.pem
callback_whitelist = foreman
bin_ansible_callbacks = True
callback_plugins   = /usr/share/ansible/plugins/callback
stdout_callback = yaml



i am getting error below 


any suggestions Please ?


TASK [Gathering Facts] ***********************************************************************************************************************************************************************************
ok: [xxx]
[WARNING]: Failure using method (v2_runner_on_ok) in callback plugin (<ansible.plugins.callback.foreman_callback.CallbackModule object at 0x7f6108061690>): 'invocation'




And the host is not getting updated in UI of forman 


Forman & ansible both are on same subnet & there is no firewall 


thanks 

Dick Visser

unread,
Aug 10, 2020, 4:42:09 AM8/10/20
to ansible...@googlegroups.com
This list is for generic ansible issues.
Your issue seems highly specific to a 3rd party module. I would try
that community first:

https://github.com/theforeman/foreman_ansible#foreman-ansible-arrow_forward
> --
> 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 view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/4cb6411b-4f8a-4c30-ae71-db5299a69aa5o%40googlegroups.com.



--
Dick Visser
Trust & Identity Service Operations Manager
GÉANT
Reply all
Reply to author
Forward
0 new messages