Cockpit icon in foreman GUI is missing


Cockpit Icon in Foreman is not visible

Expected outcome:

Cockpit Icon should be visible in the host section

Foreman and Proxy versions:

OS: CentOS Linux release 7.5.1804 (Core)

Foreman and Proxy plugin versions:

Other relevant data:
[e.g. logs from Foreman and/or the Proxy, modified templates, commands issued, etc]

I installed Foreman 1.18 and the Foreman Cockpit plugin. Cockpit is also running on the Foreman host.

The Cockpit GUI is working fine and the Foreman Gui seems also have no problem.

If i go under the Hosts and click on the Foreman host in the gui, the Cockpit Icon is missing. I did all steps based on the documentation. I am search a lot in the Internet about this Problem and found some issues which are related to a Foreman + katello Installation which have port conflicts (9090). But i have no katello installed. The Foreman Proxy is not running on this port. I also tried to change the Cockpit port and configfiles of Foreman to use the port 9091 for Cockpit. This modification not solve the issue.

iptables is also disabled on this Hosts.

The only warning i found in the production logfile. But i am sure if this is related to that issue:
2018-09-17T09:42:43 [I|app|57989] Completed 201 Created in 136ms (Views: 13.9ms | ActiveRecord: 32.4ms)
2018-09-17T10:00:06 [W|app|] ForemanCockpit: skipping engine hook (undefined method alias_method_chain' for HostsHelper:Module Did you mean? alias_method) 2018-09-17T10:00:06 [I|dyn|] start terminating throttle_limiter... 2018-09-17T10:00:06 [I|dyn|] start terminating client dispatcher... 2018-09-17T10:00:06 [I|dyn|] stop listening for new events... 2018-09-17T10:00:06 [W|app|] ForemanCockpit: skipping engine hook (undefined methodalias_method_chain’ for HostsHelper:Module
Did you mean? alias_method)
2018-09-17T10:00:06 [I|dyn|] start terminating clock…
2018-09-17T10:00:06 [I|dyn|] start terminating throttle_limiter…
2018-09-17T10:00:06 [I|dyn|] start terminating client dispatcher…

I also tried to do a Setup with the newer Foreman Version 1.19, but it is still the same behavior.

Hope someone can help me to solve this issue.



cockpit icon/button only appears when your managed host has port 9090 opened and it is reachable from your browser. You need to start and enable cockpit on the host, not Foreman. Also check your firewalls, browser needs direct connection unfortunately. This is how it works, it’s very simple integration.

Your browser -> Foreman (port 443)
Your browser -> Managed host (port 9090)


I don’t think it’s as simple as your post lzap, the problem is — the icon for Cockpit isn’t showing up in the UI.
The error populating production.log as follows: 2018-09-17T10:30:28 [W|app|] ForemanCockpit: skipping engine hook (undefined method `alias_method_chain’ for HostsHelper:Module

After digging into all this; I’ve found the fix. Which is not part of the distribution right now btw.

This will fix the problem:

Katello 3.8, and Foreman 1.19


Thanks a lot!

I changed the config file as you told me and it works now. Now i have to fix the untrusted Connection but i think this should be not so difficult.