Class: Ansible::Ruby::Modules::Haproxy
- Inherits:
-
Base
- Object
- Ansible::Ruby::Models::Base
- Base
- Ansible::Ruby::Modules::Haproxy
- Defined in:
- lib/ansible/ruby/modules/generated/net_tools/haproxy.rb
Overview
Enable, disable, drain and set weights for HAProxy backend servers using socket commands.
Instance Method Summary collapse
-
#backend ⇒ String?
Name of the HAProxy backend pool.
-
#drain ⇒ Boolean?
Wait until the server has no active connections or until the timeout determined by wait_interval and wait_retries is reached.
-
#fail_on_not_found ⇒ :yes, ...
Fail whenever trying to enable/disable a backend host that does not exist.
-
#host ⇒ String
Name of the backend host to change.
-
#shutdown_sessions ⇒ :yes, ...
When disabling a server, immediately terminate all the sessions attached to the specified server.
-
#socket ⇒ String?
Path to the HAProxy socket file.
-
#state ⇒ :enabled, ...
Desired state of the provided backend host.,Note that C(drain) state was added in version 2.4.
-
#wait ⇒ :yes, ...
Wait until the server reports a status of ‘UP’ when ‘state=enabled`, status of ’MAINT’ when ‘state=disabled` or status of ’DRAIN’ when ‘state=drain`.
-
#wait_interval ⇒ Integer?
Number of seconds to wait between retries.
-
#wait_retries ⇒ Integer?
Number of times to check for status after changing the state.
-
#weight ⇒ Integer?
The value passed in argument.
Methods inherited from Base
Methods inherited from Ansible::Ruby::Models::Base
attr_option, attr_options, attribute, fix_inclusion, #initialize, remove_existing_validations, #to_h, validates
Constructor Details
This class inherits a constructor from Ansible::Ruby::Models::Base
Instance Method Details
#backend ⇒ String?
Returns Name of the HAProxy backend pool.
12 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 12 attribute :backend |
#drain ⇒ Boolean?
Returns Wait until the server has no active connections or until the timeout determined by wait_interval and wait_retries is reached. Continue only after the status changes to ‘MAINT’. This overrides the shutdown_sessions option.
16 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 16 attribute :drain |
#fail_on_not_found ⇒ :yes, ...
Returns Fail whenever trying to enable/disable a backend host that does not exist.
36 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 36 attribute :fail_on_not_found |
#host ⇒ String
Returns Name of the backend host to change.
20 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 20 attribute :host |
#shutdown_sessions ⇒ :yes, ...
Returns When disabling a server, immediately terminate all the sessions attached to the specified server. This can be used to terminate long-running sessions after a server is put into maintenance mode. Overridden by the drain option.
24 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 24 attribute :shutdown_sessions |
#socket ⇒ String?
Returns Path to the HAProxy socket file.
28 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 28 attribute :socket |
#state ⇒ :enabled, ...
Returns Desired state of the provided backend host.,Note that C(drain) state was added in version 2.4. It is supported only by HAProxy version 1.5 or later, if used on versions < 1.5, it will be ignored.
32 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 32 attribute :state |
#wait ⇒ :yes, ...
Returns Wait until the server reports a status of ‘UP’ when ‘state=enabled`, status of ’MAINT’ when ‘state=disabled` or status of ’DRAIN’ when ‘state=drain`.
40 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 40 attribute :wait |
#wait_interval ⇒ Integer?
Returns Number of seconds to wait between retries.
44 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 44 attribute :wait_interval |
#wait_retries ⇒ Integer?
Returns Number of times to check for status after changing the state.
48 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 48 attribute :wait_retries |
#weight ⇒ Integer?
Returns The value passed in argument. If the value ends with the ‘%` sign, then the new weight will be relative to the initially configured weight. Relative weights are only permitted between 0 and 100% and absolute weights are permitted between 0 and 256.
52 |
# File 'lib/ansible/ruby/modules/generated/net_tools/haproxy.rb', line 52 attribute :weight |