Skip to content

Commit

Permalink
Merge pull request #260 from Telekom-PD/fix_hosts_update_hang
Browse files Browse the repository at this point in the history
Fix hang on systems with interactive rm
  • Loading branch information
seth-reeser committed Apr 17, 2018
2 parents 81079f7 + 33e23bf commit eddb711
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/vagrant-hostmanager/hosts_file/updater.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def update_guest(machine)
if windir
machine.communicate.sudo("mv -force /tmp/hosts.#{machine.name} #{realhostfile}")
else
machine.communicate.sudo("cat /tmp/hosts.#{machine.name} > #{realhostfile} && rm /tmp/hosts.#{machine.name}")
machine.communicate.sudo("cat /tmp/hosts.#{machine.name} > #{realhostfile} && rm -f /tmp/hosts.#{machine.name}")
end
end

Expand Down

0 comments on commit eddb711

Please sign in to comment.