Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-26 Thread automation
gerrit-hooks has posted comments on this change.

Change subject: net: set netconf/* owner to 'vdsm'
..


Patch Set 3:

* #1294075::Update tracker: OK
* Set MODIFIED::bug 1294075#1294075IGNORE, not oVirt classification but 
Red Hat

-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Edward Haas 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-26 Thread danken
Dan Kenigsberg has submitted this change and it was merged.

Change subject: net: set netconf/* owner to 'vdsm'
..


net: set netconf/* owner to 'vdsm'

On ovirt-node netconf/* has umask of 660 with root
as owner. Accessing the folders and files by vdsm
is denied.
Resolved by changing the owner of the files and
folders to 'vdsm'

Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Bug-Url: https://bugzilla.redhat.com/1294075
Signed-off-by: Edward Haas 
Reviewed-on: https://gerrit.ovirt.org/50984
Continuous-Integration: Jenkins CI
Reviewed-by: Dan Kenigsberg 
Reviewed-on: https://gerrit.ovirt.org/51053
(cherry picked from commit a47bbd992245a9e1bedcf69afedfe60aa0e36881)
Reviewed-on: https://gerrit.ovirt.org/51060
Continuous-Integration: Dan Kenigsberg 
---
M lib/vdsm/netconfpersistence.py
M tests/netconfpersistenceTests.py
M tests/netinfoTests.py
3 files changed, 11 insertions(+), 0 deletions(-)

Approvals:
  Dan Kenigsberg: Looks good to me, approved; Passed CI tests
  Edward Haas: Verified

Objections:
  Jenkins CI: Failed CI tests



-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Edward Haas 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-24 Thread danken
Dan Kenigsberg has posted comments on this change.

Change subject: net: set netconf/* owner to 'vdsm'
..


Patch Set 2: Code-Review+2

-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Edward Haas 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-24 Thread danken
Dan Kenigsberg has posted comments on this change.

Change subject: net: set netconf/* owner to 'vdsm'
..


Patch Set 2: Continuous-Integration+1

Unrelated indeed.

15:39:05 FAIL: test_discarded_workers (executorTests.ExecutorTests)
15:39:05 --
15:39:05 Traceback (most recent call last):
15:39:05   File 
"/home/jenkins/workspace/vdsm_3.5_check-patch-fc22-x86_64/vdsm/tests/testValidation.py",
 line 139, in wrapper
15:39:05 return f(*args, **kwargs)
15:39:05   File 
"/home/jenkins/workspace/vdsm_3.5_check-patch-fc22-x86_64/vdsm/tests/executorTests.py",
 line 123, in test_discarded_workers
15:39:05 self.assertTrue(task.executed.is_set())
15:39:05 AssertionError: False is not true

-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Edward Haas 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-24 Thread edwardh
Edward Haas has posted comments on this change.

Change subject: net: set netconf/* owner to 'vdsm'
..


Patch Set 2:

CI failures do not seem to be related to this patch.

-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Edward Haas 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-24 Thread edwardh
Edward Haas has posted comments on this change.

Change subject: net: set netconf/* owner to 'vdsm'
..


Patch Set 2: Verified+1

-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Edward Haas 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-24 Thread automation
gerrit-hooks has posted comments on this change.

Change subject: net: set netconf/* owner to 'vdsm'
..


Patch Set 2:

* #1294075::Update tracker: OK
* Check Bug-Url::OK
* Check Public Bug::#1294075::OK, public bug
* Check Product::#1294075::OK, Correct product Red Hat Enterprise 
Virtualization Manager
* Check TM::#1294075::OK, correct target milestone ovirt-3.5.7
* Check merged to previous::OK, change not open on any previous branch

-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-24 Thread automation
gerrit-hooks has posted comments on this change.

Change subject: net: set netconf/* owner to 'vdsm'
..


Patch Set 1:

* #1294075::Update tracker: OK
* Check Bug-Url::OK
* Check Public Bug::#1294075::OK, public bug
* Check Product::#1294075::OK, Correct product Red Hat Enterprise 
Virtualization Manager
* Check TM::#1294075::OK, correct target milestone ovirt-3.5.7
* Check merged to previous::OK, change not open on any previous branch

-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[ovirt-3.5]: net: set netconf/* owner to 'vdsm'

2015-12-24 Thread edwardh
Edward Haas has uploaded a new change for review.

Change subject: net: set netconf/* owner to 'vdsm'
..

net: set netconf/* owner to 'vdsm'

On ovirt-node netconf/* has umask of 660 with root
as owner. Accessing the folders and files by vdsm
is denied.
Resolved by changing the owner of the files and
folders to 'vdsm'

Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Bug-Url: https://bugzilla.redhat.com/1294075
Signed-off-by: Edward Haas 
Reviewed-on: https://gerrit.ovirt.org/50984
Continuous-Integration: Jenkins CI
Reviewed-by: Dan Kenigsberg 
Reviewed-on: https://gerrit.ovirt.org/51053
(cherry picked from commit a47bbd992245a9e1bedcf69afedfe60aa0e36881)
---
M lib/vdsm/netconfpersistence.py
M tests/netconfpersistenceTests.py
2 files changed, 9 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/60/51060/1

diff --git a/lib/vdsm/netconfpersistence.py b/lib/vdsm/netconfpersistence.py
index cbb159e..1be6f32 100644
--- a/lib/vdsm/netconfpersistence.py
+++ b/lib/vdsm/netconfpersistence.py
@@ -24,6 +24,7 @@
 import logging
 import netaddr
 import os
+import pwd
 import string
 
 from .config import config
@@ -156,6 +157,11 @@
 with open(path, 'w') as configurationFile:
 json.dump(config, configurationFile)
 
+# Set owner to vdsm (required by ovirt-node)
+vdsm_uid = pwd.getpwnam(constants.VDSM_USER).pw_uid
+os.chown(dirPath, vdsm_uid, 0)
+os.chown(path, vdsm_uid, 0)
+
 @staticmethod
 def _removeConfig(path):
 utils.rmFile(path)
diff --git a/tests/netconfpersistenceTests.py b/tests/netconfpersistenceTests.py
index f997800..aad5be8 100644
--- a/tests/netconfpersistenceTests.py
+++ b/tests/netconfpersistenceTests.py
@@ -19,7 +19,9 @@
 #
 
 import json
+from monkeypatch import MonkeyPatch
 import os
+import pwd
 from shutil import rmtree
 import tempfile
 
@@ -69,6 +71,7 @@
 persistence.removeBonding(BONDING)
 self.assertTrue(persistence.bonds.get(BONDING) is None)
 
+@MonkeyPatch(pwd, 'getpwnam', lambda name: pwd.getpwuid(os.geteuid()))
 def testSaveAndDelete(self):
 persistence = Config(self.tempdir)
 persistence.setNetwork(NETWORK, NETWORK_ATTRIBUTES)


-- 
To view, visit https://gerrit.ovirt.org/51060
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I65725c698bdd3cd3a51a3327b33ce9b16292820a
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Edward Haas 
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches