Class: VagrantAutoDNS::Plugin
- Inherits:
-
Object
- Object
- VagrantAutoDNS::Plugin
- Defined in:
- lib/vagrant-autodns/plugin.rb
Class Method Summary collapse
Class Method Details
.after_destroy ⇒ Object
74 75 76 77 78 79 80 81 82 83 |
# File 'lib/vagrant-autodns/plugin.rb', line 74 def self.after_destroy require_relative 'actions/delete' require_relative 'actions/teardown' ::Vagrant::Action::Builder.new.tap do |builder| #Remove all hostname entries for guest builder.use Action::Delete #Shutdown daemon if not needed builder.use Action::Teardown end end |
.after_set_hostname ⇒ Object
60 61 62 63 64 65 66 67 68 69 70 71 72 |
# File 'lib/vagrant-autodns/plugin.rb', line 60 def self.after_set_hostname require_relative 'actions/start' require_relative 'actions/add' require_relative 'actions/redirect_dns' ::Vagrant::Action::Builder.new.tap do |builder| #Starts the AutoDNSDB Daemon builder.use Action::Start #Adds guest hostname records to AutoDNSDB builder.use Action::Add #Redirect guest DNS to daemon with IP tables builder.use Action::RedirectDNS end end |