summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVitalii Koriakov <vkoriako@redhat.com>2018-11-05 14:34:55 +0200
committerVijay Avuthu <vavuthu@redhat.com>2018-11-08 10:34:34 +0000
commit0adfb628fbbd7a2edd5c2be6e8c8c1c5c8ecbba0 (patch)
tree019600915e09ec3d18a292beefac09b331fffa9a
parenteb2193769bd61cd24eb7efb414ad007cb13c9f96 (diff)
Convert geo_rep_ops to python3
Change-Id: I2f491f7cadd92846730c6528920c9fa8c2c9edce Signed-off-by: Vitalii Koriakov <vkoriako@redhat.com>
-rwxr-xr-x[-rw-r--r--]glustolibs-gluster/glustolibs/gluster/geo_rep_ops.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/glustolibs-gluster/glustolibs/gluster/geo_rep_ops.py b/glustolibs-gluster/glustolibs/gluster/geo_rep_ops.py
index aa89f19..8acec0d 100644..100755
--- a/glustolibs-gluster/glustolibs/gluster/geo_rep_ops.py
+++ b/glustolibs-gluster/glustolibs/gluster/geo_rep_ops.py
@@ -123,7 +123,7 @@ def georep_groupadd(servers, groupname):
results = g.run_parallel(servers, cmd)
_rc = True
- for server, ret_value in results.iteritems():
+ for server, ret_value in list(results.items()):
retcode, _, err = ret_value
if retcode != 0 and "already exists" not in err:
g.log.error("Unable to add group %s on server %s",
@@ -153,7 +153,7 @@ def georep_geoaccount(servers, groupname, groupaccount):
results = g.run_parallel(servers, cmd)
_rc = True
- for server, ret_value in results.iteritems():
+ for server, ret_value in list(results.items()):
retcode, _, err = ret_value
if retcode != 0 and "already exists" not in err:
g.log.error("Unable to add user on %s", server)
@@ -183,7 +183,7 @@ def georep_geoaccount_setpasswd(servers, groupname, groupaccount, passwd):
results = g.run_parallel(servers, cmd)
_rc = True
- for server, ret_value in results.iteritems():
+ for server, ret_value in list(results.items()):
retcode, _, err = ret_value
if retcode != 0:
g.log.error("Unable to set passwd for user %s on %s",