Class: Landrush::Action::Setup
- Inherits:
-
Object
- Object
- Landrush::Action::Setup
show all
- Includes:
- Common
- Defined in:
- lib/landrush/action/setup.rb
Constant Summary
Constants included
from Common
Common::SUPPORTED_PROVIDERS
Instance Method Summary
collapse
Methods included from Common
#config, #enabled?, #guest_redirect_dns?, included, #info, #initialize, #libvirt?, #log, #machine, #machine_hostname, #parallels?, #provider, #read_machine_hostname, #virtualbox?, #vmware?
Instance Method Details
#call(env) ⇒ Object
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
# File 'lib/landrush/action/setup.rb', line 6
def call(env)
Server.working_dir = File.join(env[:home_path], 'data', 'landrush')
Server.gems_dir = File.join(env[:gems_path].to_s, 'gems')
Server.ui = env[:ui]
pre_boot_setup if enabled?
app.call(env)
post_boot_setup if enabled?
end
|
#host_ip_address ⇒ Object
21
22
23
24
25
26
27
|
# File 'lib/landrush/action/setup.rb', line 21
def host_ip_address
if private_network_ips.include? machine.config.landrush.host_ip_address
machine.config.landrush.host_ip_address
else
machine.guest.capability(:read_host_visible_ip_address)
end
end
|