Method: Fog::Compute::AWS::Real#detach_internet_gateway

Defined in:
lib/fog/aws/requests/compute/detach_internet_gateway.rb

#detach_internet_gateway(internet_gateway_id, vpc_id) ⇒ Object

Detaches an Internet gateway to a VPC, enabling connectivity between the Internet and the VPC

Parameters

  • internet_gateway_id<~String> - The ID of the Internet gateway to detach

  • vpc_id<~String> - The ID of the VPC

Returns

  • response<~Excon::Response>:

    • body<~Hash>:

      • ‘requestId’<~String> - Id of request

      • ‘return’<~Boolean> - Returns true if the request succeeds.

Amazon API Reference


20
21
22
23
24
25
26
27
28
# File 'lib/fog/aws/requests/compute/detach_internet_gateway.rb', line 20

def detach_internet_gateway(internet_gateway_id, vpc_id)
  request(
    'Action'               => 'DetachInternetGateway',
    'InternetGatewayId'    => internet_gateway_id,
    'VpcId'                => vpc_id,
    :idempotent   => true,
    :parser       => Fog::Parsers::Compute::AWS::DetachInternetGateway.new
  )
end