diff --git a/lib/fog/aws/parsers/compute/spot_instance_requests.rb b/lib/fog/aws/parsers/compute/spot_instance_requests.rb index 0e6f3c37d..d8a481b52 100644 --- a/lib/fog/aws/parsers/compute/spot_instance_requests.rb +++ b/lib/fog/aws/parsers/compute/spot_instance_requests.rb @@ -6,7 +6,7 @@ module Fog def reset @block_device_mapping = {} @context = [] - @contexts = ['blockDeviceMapping', 'groupSet', 'iamInstanceProfile'] + @contexts = ['blockDeviceMapping', 'groupSet', 'iamInstanceProfile', 'networkInterfaceSet'] @spot_instance_request = { 'launchSpecification' => { 'iamInstanceProfile' => {}, 'blockDeviceMapping' => [], 'groupSet' => [] } } @response = { 'spotInstanceRequestSet' => [] } end @@ -34,7 +34,9 @@ module Fog when 'deviceName', 'status', 'volumeId' @block_device_mapping[name] = value when 'groupId' - @spot_instance_request['launchSpecification']['groupSet'] << value + if !@context.include?('networkInterfaceSet') + @spot_instance_request['launchSpecification']['groupSet'] << value + end when 'arn', 'name' @spot_instance_request['launchSpecification']['iamInstanceProfile'][name] = value when 'instanceId', 'launchedAvailabilityZone', 'productDescription', 'spotInstanceRequestId', 'state', 'type'