Class: AWS::ELB::LoadBalancer
- Inherits:
-
Object
- Object
- AWS::ELB::LoadBalancer
- Defined in:
- lib/kelbim/ext/elb-load-balancer-ext.rb
Instance Method Summary collapse
Instance Method Details
#attributes ⇒ Object
14 15 16 17 18 19 20 21 22 23 |
# File 'lib/kelbim/ext/elb-load-balancer-ext.rb', line 14 def attributes unless @attributes credentials = AWS.config.credential_provider.credentials elb = AWS::ELB.new(credentials) @attributes = elb.client.describe_load_balancer_attributes( :load_balancer_name => self.name).data[:load_balancer_attributes] end return @attributes.dup end |
#attributes=(attrs) ⇒ Object
25 26 27 28 29 30 31 32 33 34 35 |
# File 'lib/kelbim/ext/elb-load-balancer-ext.rb', line 25 def attributes=(attrs) credentials = AWS.config.credential_provider.credentials elb = AWS::ELB.new(credentials) elb.client.modify_load_balancer_attributes({ :load_balancer_name => self.name, :load_balancer_attributes => attrs, }) (@attributes = attrs).dup end |