mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
[aws|beanstalk] Update parser for DescribeEnvironmentResources
Updated parser to handle both new and "legacy" beanstalk stacks. Updated Environment#load_balancer to return correct result for both stack types.
This commit is contained in:
parent
0c1ddd97c7
commit
5d3785ba70
2 changed files with 17 additions and 2 deletions
|
@ -47,8 +47,12 @@ module Fog
|
|||
|
||||
# Returns the load balancer object associated with the environment.
|
||||
def load_balancer(elb_connection = Fog::AWS[:elb])
|
||||
requires :resources
|
||||
elb_connection.load_balancers.get(resources['LoadBalancer']['LoadBalancerName'])
|
||||
|
||||
if resources.nil?
|
||||
elb_connection.load_balancers.get(live_resources['LoadBalancers'].first['Name'])
|
||||
else
|
||||
elb_connection.load_balancers.get(resources['LoadBalancer']['LoadBalancerName'])
|
||||
end
|
||||
end
|
||||
|
||||
# Return events related to this version
|
||||
|
|
|
@ -16,6 +16,17 @@ module Fog
|
|||
tag 'Id', :string
|
||||
tag 'LaunchConfigurations', :object, :list
|
||||
tag 'LoadBalancers', :object, :list
|
||||
tag 'Resources', :object, :list
|
||||
tag 'Description', :string
|
||||
tag 'LogicalResourceId', :string
|
||||
tag 'PhysicalResourceId', :string
|
||||
tag 'Type', :string
|
||||
tag 'Properties', :object, :list
|
||||
tag 'RuntimeSources', :object, :list
|
||||
tag 'Parameter', :string
|
||||
tag 'Versions', :object, :list
|
||||
tag 'ApplicationName', :string
|
||||
tag 'VersionLabel', :string
|
||||
tag 'Triggers', :object, :list
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue