Douglas Schilling Landgraf has uploaded a new change for review.

Change subject: engine_page: unpersist/persist /etc/default/ovirt
......................................................................

engine_page: unpersist/persist /etc/default/ovirt

Before saving new data into /etc/default/ovirt we must
unpersist it and after changing the data persist.

Change-Id: Ic500a92aaff60a24d5d1dbd444b3397e9706a198
Signed-off-by: Douglas Schilling Landgraf <dougsl...@redhat.com>
---
M src/engine_page.py
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node-plugin-vdsm 
refs/changes/77/32877/1

diff --git a/src/engine_page.py b/src/engine_page.py
index ac72c84..0209b0c 100644
--- a/src/engine_page.py
+++ b/src/engine_page.py
@@ -116,6 +116,7 @@
             proto = "http"
         engine_data = '"oVirt Engine %s://%s"' % (proto, ":".join(server_url))
 
+    utils.fs.Config().unpersist("/etc/default/ovirt")
     ag = augeas.Augeas()
     ag.set("/files/etc/default/ovirt/MANAGED_IFNAMES", "\"%s\"" %
            ''.join(mgmtIface).encode('utf-8'))
@@ -127,6 +128,7 @@
         ag.set("/files/etc/default/ovirt/MANAGED_BY",
                engine_data.encode('utf-8'))
     ag.save()
+    utils.fs.Config().persist("/etc/default/ovirt")
 
 
 class Plugin(plugins.NodePlugin):


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic500a92aaff60a24d5d1dbd444b3397e9706a198
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node-plugin-vdsm
Gerrit-Branch: master
Gerrit-Owner: Douglas Schilling Landgraf <dougsl...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to