[node-patches] Change in ovirt-node[master]: plugins: Let some plugins publish their features
fabiand at fedoraproject.org
fabiand at fedoraproject.org
Fri Aug 30 12:06:13 UTC 2013
Fabian Deutsch has uploaded a new change for review.
Change subject: plugins: Let some plugins publish their features
......................................................................
plugins: Let some plugins publish their features
Change-Id: I164f5038c6e68cdf8faf56061a74bd07dc1a86a6
Signed-off-by: Fabian Deutsch <fabiand at fedoraproject.org>
---
M src/ovirt/node/installer/core/__init__.py
M src/ovirt/node/setup/cim/__init__.py
M src/ovirt/node/setup/core/__init__.py
M src/ovirt/node/setup/puppet/__init__.py
M src/ovirt/node/setup/snmp/__init__.py
5 files changed, 33 insertions(+), 5 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/17/18717/1
diff --git a/src/ovirt/node/installer/core/__init__.py b/src/ovirt/node/installer/core/__init__.py
index b460fbd..bdc683c 100644
--- a/src/ovirt/node/installer/core/__init__.py
+++ b/src/ovirt/node/installer/core/__init__.py
@@ -22,7 +22,7 @@
"""
Core Installer Plugins
"""
-from ovirt.node import plugins, loader
+from ovirt.node import loader
#
diff --git a/src/ovirt/node/setup/cim/__init__.py b/src/ovirt/node/setup/cim/__init__.py
index 6eed806..578f450 100644
--- a/src/ovirt/node/setup/cim/__init__.py
+++ b/src/ovirt/node/setup/cim/__init__.py
@@ -18,11 +18,12 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
# MA 02110-1301, USA. A copy of the GNU General Public License is
# also available at http://www.gnu.org/copyleft/gpl.html.
+from ovirt.node.utils.feature import Feature, Owner
+import cim_page
"""
CIM Plugin
"""
-import cim_page
#
@@ -30,3 +31,9 @@
#
def createPlugins(application):
cim_page.Plugin(application)
+
+
+def createPluginFeatures(application):
+ application.register(Feature(owner=Owner(name=__package__),
+ name="cim",
+ description="Offers informations via CIM"))
diff --git a/src/ovirt/node/setup/core/__init__.py b/src/ovirt/node/setup/core/__init__.py
index cb3b024..23704ca 100644
--- a/src/ovirt/node/setup/core/__init__.py
+++ b/src/ovirt/node/setup/core/__init__.py
@@ -18,11 +18,12 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
# MA 02110-1301, USA. A copy of the GNU General Public License is
# also available at http://www.gnu.org/copyleft/gpl.html.
+from ovirt.node import loader
+from ovirt.node.utils.feature import Owner, Feature
"""
Core Setup Plugins
"""
-from ovirt.node import loader
#
@@ -37,3 +38,9 @@
# Lazy load all plugins in this package
for plugin in all_modules():
plugin.Plugin(application)
+
+
+def createPluginFeatures(application):
+ application.register(Feature(owner=Owner(name=__package__),
+ name="ui",
+ description="Has a UI"))
diff --git a/src/ovirt/node/setup/puppet/__init__.py b/src/ovirt/node/setup/puppet/__init__.py
index 896b241..92f1686 100644
--- a/src/ovirt/node/setup/puppet/__init__.py
+++ b/src/ovirt/node/setup/puppet/__init__.py
@@ -18,11 +18,12 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
# MA 02110-1301, USA. A copy of the GNU General Public License is
# also available at http://www.gnu.org/copyleft/gpl.html.
+from ovirt.node.utils.feature import Feature, Owner
+import puppet_page
"""
Puppet Plugin
"""
-import puppet_page
#
@@ -30,3 +31,9 @@
#
def createPlugins(application):
puppet_page.Plugin(application)
+
+
+def createPluginFeatures(application):
+ application.register(Feature(owner=Owner(name=__package__),
+ name="puppet",
+ description="Offers provisioning via puppet"))
diff --git a/src/ovirt/node/setup/snmp/__init__.py b/src/ovirt/node/setup/snmp/__init__.py
index 63a5328..5eecbeb 100644
--- a/src/ovirt/node/setup/snmp/__init__.py
+++ b/src/ovirt/node/setup/snmp/__init__.py
@@ -18,11 +18,12 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
# MA 02110-1301, USA. A copy of the GNU General Public License is
# also available at http://www.gnu.org/copyleft/gpl.html.
+from ovirt.node.utils.feature import Owner, Feature
+import snmp_page
"""
SNMP Plugin
"""
-import snmp_page
#
@@ -30,3 +31,9 @@
#
def createPlugins(application):
snmp_page.Plugin(application)
+
+
+def createPluginFeatures(application):
+ application.register(Feature(owner=Owner(name=__package__),
+ name="snmp",
+ description="Offers informations via SNMP"))
--
To view, visit http://gerrit.ovirt.org/18717
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I164f5038c6e68cdf8faf56061a74bd07dc1a86a6
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: Fabian Deutsch <fabiand at fedoraproject.org>
More information about the node-patches
mailing list