Alon Bar-Lev has uploaded a new change for review.

Change subject: vdsm: packages: enforce network service
......................................................................

vdsm: packages: enforce network service

current implementation enforces network service only if bridge plugin is
enabled. While in ovirt-engine-3.3 the bridge is optional.

new implementation perform this unconditionally in the packages plugin.

Change-Id: I96ca90aa975c92439ba33309381462a052e44c5e
Signed-off-by: Alon Bar-Lev <[email protected]>
---
M src/plugins/ovirt-host-deploy/vdsm/bridge.py
M src/plugins/ovirt-host-deploy/vdsm/packages.py
2 files changed, 11 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-host-deploy 
refs/changes/04/17304/1

diff --git a/src/plugins/ovirt-host-deploy/vdsm/bridge.py 
b/src/plugins/ovirt-host-deploy/vdsm/bridge.py
index fd3a172..8c2b561 100644
--- a/src/plugins/ovirt-host-deploy/vdsm/bridge.py
+++ b/src/plugins/ovirt-host-deploy/vdsm/bridge.py
@@ -802,12 +802,5 @@
             retries=self.environment[odeploycons.VdsmEnv.CONNECTION_RETRIES],
         )
 
-    @plugin.event(
-        stage=plugin.Stages.STAGE_CLOSEUP,
-        condition=lambda self: self._enabled,
-    )
-    def _closeup(self):
-        self.services.startup('network', True)
-
 
 # vim: expandtab tabstop=4 shiftwidth=4
diff --git a/src/plugins/ovirt-host-deploy/vdsm/packages.py 
b/src/plugins/ovirt-host-deploy/vdsm/packages.py
index 3c2757b..7ae717f 100644
--- a/src/plugins/ovirt-host-deploy/vdsm/packages.py
+++ b/src/plugins/ovirt-host-deploy/vdsm/packages.py
@@ -164,6 +164,17 @@
                 self.services.state('messagebus', True)
             if self.services.exists('libvirtd'):
                 self.services.state('libvirtd', True)
+
+        #
+        # vdsm requires network to be active
+        # it cannot depend on this service as
+        # it will be stopped when network is stopped
+        # so we do this manually.
+        #
+        if self.services.exists('network'):
+            self.services.state('network', True)
+            self.services.startup('network', True)
+
         self.services.state('vdsmd', True)
 
 


-- 
To view, visit http://gerrit.ovirt.org/17304
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I96ca90aa975c92439ba33309381462a052e44c5e
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-host-deploy
Gerrit-Branch: master
Gerrit-Owner: Alon Bar-Lev <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to