class AWS::EC2::CustomerGatewayCollection

def [] customer_gateway_id

Returns:
  • (CustomerGateway) -

Parameters:
  • customer_gateway_id (String) --
def [] customer_gateway_id
  CustomerGateway.new(customer_gateway_id, :config => config)
end

def _each_item options = {}, &block

def _each_item options = {}, &block
  response = filtered_request(:describe_customer_gateways, options, &block)
  response.customer_gateway_set.each do |g|
    gateway = CustomerGateway.new_from(:describe_customer_gateways, g, 
      g.customer_gateway_id, :config => config)
    yield(gateway)
  end
end

def create bgp_asn, ip_address, options = {}

Returns:
  • (CustomerGateway) -

Options Hash: (**options)
  • :vpn_type (String) -- The type of VPN

Parameters:
  • options (Hash) --
  • ip_address (String) -- The Internet-routable IP address for the
  • bgp_asn (Integer) -- The customer gateway's Border Gateway
def create bgp_asn, ip_address, options = {}
  client_opts = {}
  client_opts[:bgp_asn] = bgp_asn
  client_opts[:public_ip] = ip_address
  client_opts[:type] = options[:vpn_type] || 'ipsec.1'
  resp = client.create_customer_gateway(client_opts)
  CustomerGateway.new_from(:create_customer_gateway, 
    resp.customer_gateway,
    resp.customer_gateway.customer_gateway_id,
    :config => config)
end