Skip to content
Browse files

Remove the network config file after appending to /etc/rc.conf

  • Loading branch information...
1 parent 7e56d19 commit afa33587e01ffe3e086a0e0ee6c710e637fc1fef @halorgium halorgium committed Feb 28, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/vagrant/guest/freebsd.rb
View
2 lib/vagrant/guest/freebsd.rb
@@ -66,7 +66,7 @@ def configure_networks(networks)
entry = TemplateRenderer.render("guests/freebsd/network_#{network[:type]}",
:options => network)
vm.channel.upload(StringIO.new(entry), "/tmp/vagrant-network-entry")
- vm.channel.sudo("su -m root -c 'cat /tmp/vagrant-network-entry >> /etc/rc.conf'")
+ vm.channel.sudo("su -m root -c 'cat /tmp/vagrant-network-entry >> /etc/rc.conf' && rm /tmp/vagrant-network-entry")
if network[:type].to_sym == :static
vm.channel.sudo("ifconfig em#{network[:interface]} inet #{network[:ip]} netmask #{network[:netmask]}")
elsif network[:type].to_sym == :dhcp

0 comments on commit afa3358

Please sign in to comment.
Something went wrong with that request. Please try again.