|
|
@ -292,11 +292,9 @@ class Zfs(object):
|
|
|
|
if self.module.check_mode:
|
|
|
|
if self.module.check_mode:
|
|
|
|
self.changed = True
|
|
|
|
self.changed = True
|
|
|
|
return
|
|
|
|
return
|
|
|
|
cmd = [self.module.get_bin_path('zfs', True)]
|
|
|
|
cmd = self.module.get_bin_path('zfs', True)
|
|
|
|
cmd.append('set')
|
|
|
|
args = [cmd, 'set', prop + '=' + value, self.name]
|
|
|
|
cmd.append(prop + '=' + value)
|
|
|
|
(rc, err, out) = self.module.run_command(args)
|
|
|
|
cmd.append(self.name)
|
|
|
|
|
|
|
|
(rc, err, out) = self.module.run_command(' '.join(cmd))
|
|
|
|
|
|
|
|
if rc == 0:
|
|
|
|
if rc == 0:
|
|
|
|
self.changed = True
|
|
|
|
self.changed = True
|
|
|
|
else:
|
|
|
|
else:
|
|
|
@ -318,7 +316,7 @@ class Zfs(object):
|
|
|
|
rc, out, err = self.module.run_command(' '.join(cmd))
|
|
|
|
rc, out, err = self.module.run_command(' '.join(cmd))
|
|
|
|
properties = dict()
|
|
|
|
properties = dict()
|
|
|
|
for l in out.splitlines():
|
|
|
|
for l in out.splitlines():
|
|
|
|
p, v = l.split()[1:3]
|
|
|
|
p, v = l.split('\t')[1:3]
|
|
|
|
properties[p] = v
|
|
|
|
properties[p] = v
|
|
|
|
return properties
|
|
|
|
return properties
|
|
|
|
|
|
|
|
|
|
|
|