Module: SSHKit::Custom::DSL::Helper

Included in:
SSHKit::Custom::DSL
Defined in:
lib/sshkit/custom/dsl/helper.rb

Instance Method Summary collapse

Instance Method Details

#_config_storeObject



28
29
30
# File 'lib/sshkit/custom/dsl/helper.rb', line 28

def _config_store
  @_config_store ||= SSHKit::Custom::Config::Store
end

#active_backendObject



6
7
8
# File 'lib/sshkit/custom/dsl/helper.rb', line 6

def active_backend
  SSHKit::Custom::Config::Store.active_backend
end

#hostObject



10
11
12
# File 'lib/sshkit/custom/dsl/helper.rb', line 10

def host
  active_backend.host
end

#Host(rh) ⇒ Object



20
21
22
23
24
25
26
# File 'lib/sshkit/custom/dsl/helper.rb', line 20

def Host(rh)
  if rh.is_a?(SSHKit::Host)
    rh
  else
    SSHKit::Host.new(rh)
  end
end