diff --git a/lib/ansible/modules/extras/system/zfs.py b/lib/ansible/modules/extras/system/zfs.py index fb987017d13..0d79569d77a 100644 --- a/lib/ansible/modules/extras/system/zfs.py +++ b/lib/ansible/modules/extras/system/zfs.py @@ -198,8 +198,9 @@ class Zfs(object): if source == 'local': properties[prop] = value # Add alias for enhanced sharing properties - properties['sharenfs'] = properties.get('share.nfs', None) - properties['sharesmb'] = properties.get('share.smb', None) + if self.enhanced_sharing: + properties['sharenfs'] = properties.get('share.nfs', None) + properties['sharesmb'] = properties.get('share.smb', None) return properties