Building Heartbeat (Linux-HA) With GUI Support on Headless Gentoo Servers

I administer several Linux clusters running Heartbeat (Linux-HA). The details of my console setup is probably enough to warrant its own article. Let's just suffice to say these servers are racked and headless (without keyboard/monitors, even a KVM). As a result, they have absolute minimal X-Windows support, which is not at all unusual for servers. Despite my minimal setup on my servers, I do like a GUI from time-to-time, and the Heartbeat client (haclient.py) is a GUI I like to use.

If you want to run the Heartbeat client on your Heartbeat-enabled server, then you'll need to add the management Gentoo USE flag when you emerge the heartbeat package, as follows:

USE="management" emerge sys-cluster/heartbeat 

The management USE flag adds support for the remote management daemon (server) that allows you to run the Heartbeat GUI (client) on your desktop system, and manage any heartbeat clusters that you can access over the network - very cool! Note: This is the equivalent of adding the --enable-mgmt configure flag when Heartbeat is built.

The problem is that if you enable the remote management daemon support with current Gentoo ebuilds, the ebuild will insist on adding support for dev-python/pygtk, which is only needed if you want to run the GUI (client) on the heartbeat server. Unfortunately, on my headless servers, this dependency results in the ebuild trying to pull in another forty-eight (48) unnecessary packages! Ultimately, the emerge fails complaining that I need to rebuild packages with additional USE flags enabled (which probably results in even more packages!), all because of the pygtk dependency.