From dce5e488056c71657aab0fe7161c17321c301aed Mon Sep 17 00:00:00 2001 From: Oliver Tappe Date: Wed, 9 Jan 2008 13:38:04 +0000 Subject: * the config-demuxer now only demuxes attributes of active plugins that have been installed into the current system's vendor-OS. git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1455 95ad53e4-c205-0410-b2fa-d234c58c8868 --- config-db/OpenSLX/ConfigDB.pm | 3 +++ config-db/slxconfig-demuxer | 8 ++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) (limited to 'config-db') diff --git a/config-db/OpenSLX/ConfigDB.pm b/config-db/OpenSLX/ConfigDB.pm index 329473ce..2acffa91 100644 --- a/config-db/OpenSLX/ConfigDB.pm +++ b/config-db/OpenSLX/ConfigDB.pm @@ -2613,6 +2613,9 @@ sub aggregatedSystemFileInfoFor ); } $info->{'vendor-os'} = $vendorOS; + + my @installedPlugins = $self->fetchInstalledPlugins($vendorOS->{id}); + $info->{'installed-plugins'} = \@installedPlugins; # check if the specified kernel file really exists (follow links while # checking) and if not, find the newest kernel file that is available. diff --git a/config-db/slxconfig-demuxer b/config-db/slxconfig-demuxer index 485a7545..2085461e 100755 --- a/config-db/slxconfig-demuxer +++ b/config-db/slxconfig-demuxer @@ -45,7 +45,6 @@ use lib "$FindBin::RealBin"; use OpenSLX::Basics; use OpenSLX::ConfigDB qw(:support); use OpenSLX::ConfigFolder; -use OpenSLX::OSPlugin::Engine; use OpenSLX::Utils; my $pxeDefaultTemplate = q[NOESCAPE 0 @@ -596,12 +595,15 @@ sub writePluginConfigurationsForSystem my $attrs = $info->{attrs} || {}; - foreach my $pluginName (OpenSLX::OSPlugin::Engine->getAvailablePlugins()) { + my @activePlugins; + foreach my $pluginName (@{$info->{'installed-plugins'}}) { vlog(2, _tr("checking configuration of plugin '%s'", $pluginName)); # skip inactive plugins my $pluginScope = lc($pluginName); next unless $attrs->{"${pluginScope}::active"}; + + push @activePlugins, $pluginName; vlog(2, _tr("writing configuration file for plugin '%s'", $pluginName)); # write plugin configuration to a file: @@ -636,6 +638,8 @@ sub writePluginConfigurationsForSystem ); } } + my $activePluginStr = @activePlugins ? join ',', @activePlugins : ''; + vlog(0, _tr("active plugins: %s", $activePluginStr)); return; } -- cgit v1.2.3-55-g7522