Merge pull request #3486 from benesch/fix-rsync-owner-group-linux

guests/linux: rsync chown if either user or group incorrect [GH-3485]
This commit is contained in:
Mitchell Hashimoto 2014-04-16 09:11:53 -07:00
commit b18865edff
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ module VagrantPlugins
def self.rsync_post(machine, opts)
machine.communicate.tap do |comm|
comm.sudo("find '#{opts[:guestpath]}' ! -user #{opts[:owner]} -or ! -group #{opts[:group]} -print0 | " +
comm.sudo("find '#{opts[:guestpath]}' '(' ! -user #{opts[:owner]} -or ! -group #{opts[:group]} ')' -print0 | " +
"xargs -0 -r chown -v #{opts[:owner]}:#{opts[:group]}")
end
end