File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
lib/vagrant-hostmanager/hosts_file Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -41,11 +41,11 @@ def update_guest(machine)
4141
4242 if update_file ( file , machine , false , line_endings )
4343 # upload modified file and remove temporary file
44- machine . communicate . upload ( file . to_s , ' /tmp/hosts' )
44+ machine . communicate . upload ( file . to_s , " /tmp/hosts. #{ machine . name } " )
4545 if windir
46- machine . communicate . sudo ( "mv -force /tmp/hosts/hosts .#{ machine . name } #{ realhostfile } " )
46+ machine . communicate . sudo ( "mv -force /tmp/hosts.#{ machine . name } #{ realhostfile } " )
4747 else
48- machine . communicate . sudo ( "cat /tmp/hosts > #{ realhostfile } " )
48+ machine . communicate . sudo ( "cat /tmp/hosts. #{ machine . name } > #{ realhostfile } && rm /tmp/hosts. #{ machine . name } " )
4949 end
5050 end
5151
You can’t perform that action at this time.
0 commit comments