class AWS::EC2::VPNGatewayCollection

def [] vpn_gateway_id

Returns:
  • (VPNGateway) -

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

def _each_item options = {}, &block

def _each_item options = {}, &block
  response = filtered_request(:describe_vpn_gateways, options, &block)
  response.vpn_gateway_set.each do |g|
    gateway = VPNGateway.new_from(:describe_vpn_gateways, g, 
      g.vpn_gateway_id, :config => config)
    yield(gateway)
  end
end

def create options = {}

Returns:
  • (VPNGateway) -

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

Parameters:
  • options (Hash) --
def create options = {}
  client_opts = {}
  client_opts[:type] = options[:vpn_type] || 'ipsec.1'
  if az = options[:availability_zone]
    az = az.name if az.is_a?(AvailabilityZone)
    client_opts[:availability_zone] = az
  end
  resp = client.create_vpn_gateway(client_opts)
  VPNGateway.new_from(:create_vpn_gateway, resp.vpn_gateway,
    resp.vpn_gateway.vpn_gateway_id, :config => config)
end