Skip to content

Instantly share code, notes, and snippets.

@hedgehog
Forked from mitchellh/gist:1277049
Created December 21, 2011 13:28
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hedgehog/1506046 to your computer and use it in GitHub Desktop.
Save hedgehog/1506046 to your computer and use it in GitHub Desktop.
Configure Vagrant VM to use Host DNS for VPN
Vagrant::Config.run do |config|
# ...
config.vm.customize do |vm|
# Use the host resolver for DNS so that VPN continues
# to work within the VM
vm.network_adapters.each do |na|
if na.enabled? && na.nat_driver
na.nat_driver.dns_use_host_resolver = true
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment