From 7e1fa9f68dc88c724d339488910c6da804992998 Mon Sep 17 00:00:00 2001 From: Adam Spiers Date: Thu, 16 Jan 2014 19:22:13 +0000 Subject: [PATCH] support running hb_gui over ssh --- attributes/default.rb | 6 ++++++ recipes/setup.rb | 10 ++++++++++ 2 files changed, 16 insertions(+) diff --git a/attributes/default.rb b/attributes/default.rb index 3f37166..41ba2be 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -16,6 +16,12 @@ case node.platform when 'suse' default[:pacemaker][:platform][:packages] = %w(pacemaker) + + # pacemaker-mgmt-client provides hb_gui, which it's useful + # to run over ssh. + default[:pacemaker][:platform][:packages] += %w( + pacemaker-mgmt-client xorg-x11-xauth + ) else Chef::Application.fatal! "FIXME: #{node.platform} platform not supported yet" return diff --git a/recipes/setup.rb b/recipes/setup.rb index 3351e81..1e9ba39 100644 --- a/recipes/setup.rb +++ b/recipes/setup.rb @@ -45,3 +45,13 @@ if platform_family? "rhel" notifies :restart, "service[clvm]", :immediately end end + +# required to run hb_gui +if platform_family? "suse" + cmd = "SuSEconfig --module gtk2" + execute cmd do + user "root" + command cmd + not_if { File.exists? "/etc/gtk-2.0/gdk-pixbuf64.loaders" } + end +end