Merge pull request #15226 from cimarronm/disk_usage_darwin

disk.usage forces check for /etc/mtab
This commit is contained in:
Thomas S Hatch 2014-08-25 12:58:49 -06:00
commit 414528dc28

View File

@ -54,7 +54,7 @@ def usage(args=None):
salt '*' disk.usage
'''
flags = _clean_flags(args, 'disk.usage')
if not os.path.isfile('/etc/mtab'):
if not os.path.isfile('/etc/mtab') and __grains__['kernel'] != 'Darwin':
log.warn('df cannot run without /etc/mtab')
if __grains__.get('virtual_subtype') == 'LXC':
log.warn('df command failed and LXC detected. If you are running '