Merge pull request #1493 from abulimov/filesystem_recreate_with_force

Allow recreation of same FS with force=yes in filesystem module
This commit is contained in:
Brian Coca 2016-01-25 23:57:04 -05:00
commit ec8bf56448

View file

@ -191,7 +191,7 @@ def main():
rc,raw_fs,err = module.run_command("%s -c /dev/null -o value -s TYPE %s" % (cmd, dev))
fs = raw_fs.strip()
if fs == fstype and resizefs == False:
if fs == fstype and resizefs == False and not force:
module.exit_json(changed=False)
elif fs == fstype and resizefs == True:
# Get dev and fs size and compare