Sha256: a5da6ccd5e7e49f00b1de2515def5e4ac1aa51cf49c53a53fb8a34831db9a101
Contents?: true
Size: 741 Bytes
Versions: 3
Compression:
Stored size: 741 Bytes
Contents
module PoolParty module Plugin =begin rdoc == Host The host parameter sets hosts on the instances. Setting this, every node will have the host. == Usage has_host(:name => '...') do # More options. # This block is optional end == Options * <tt>name</tt>The name of the instance * <tt>ip</tt> IP address of the instance for the host entry == Examples has_host({:name => "other_machine", :ip => 192.168.0.101 }) =end class Host < Plugin default_options({ :name => "localhost", :ip => "127.0.0.1" }) def loaded(o={},&block) has_line_in_file(:file => "/etc/hosts", :line => "#{o[:ip]} #{o[:name]}") end end end end
Version data entries
3 entries across 3 versions & 2 rubygems
Version | Path |
---|---|
auser-poolparty-1.2.11 | lib/poolparty/plugins/host.rb |
auser-poolparty-1.2.12 | lib/poolparty/plugins/host.rb |
fairchild-poolparty-1.2.12 | lib/poolparty/plugins/host.rb |