Sha256: 84aedd727b808aa8566cf456e60a9c3bc8280171bcb8ddaac966620a2149b977

Contents?: true

Size: 993 Bytes

Versions: 85

Compression:

Stored size: 993 Bytes

Contents

module Fog
  module Compute
    class OpenStack
      class Real

        def get_address(address_id)

          request(
            :expects  => [200],
            :method   => 'GET',
            :path     => "os-floating-ips/#{address_id}"
          )
        end

      end

      class Mock
        def get_address(address_id)
          response = Excon::Response.new
          response.status = 200
          response.headers = {
            "X-Compute-Request-Id" => "req-d4a21158-a86c-44a6-983a-e25645907f26",
            "Content-Type" => "application/json",
            "Content-Length" => "105",
            "Date"=> Date.new
          }
          response.body = {
            "floating_ip" => {
              "instance_id" => nil,
              "ip" => "192.168.27.129",
              "fixed_ip" => nil,
              "id" => 1,
              "pool" => "nova"
            }
          }
          response
        end
      end # mock
    end # openstack
  end # compute
end # fog

Version data entries

85 entries across 85 versions & 13 rubygems

Version Path
fog-1.17.0 lib/fog/openstack/requests/compute/get_address.rb
fog-1.16.0 lib/fog/openstack/requests/compute/get_address.rb
fog-maestrodev-1.15.0.20130927082724 lib/fog/openstack/requests/compute/get_address.rb
fog-maestrodev-1.15.0.20130829165835 lib/fog/openstack/requests/compute/get_address.rb
fog-1.15.0 lib/fog/openstack/requests/compute/get_address.rb
gapinc-fog-1.14.0 lib/fog/openstack/requests/compute/get_address.rb
fog-maestrodev-1.14.0.20130806165225 lib/fog/openstack/requests/compute/get_address.rb
fog-1.14.0 lib/fog/openstack/requests/compute/get_address.rb
fog-1.13.0 lib/fog/openstack/requests/compute/get_address.rb
gapinc-fog-1.12.1.2 lib/fog/openstack/requests/compute/get_address.rb
gapinc-fog-1.12.1.1 lib/fog/openstack/requests/compute/get_address.rb
gapinc-fog-1.12.1a lib/fog/openstack/requests/compute/get_address.rb
gapinc-fog-1.12.1 lib/fog/openstack/requests/compute/get_address.rb
fog-1.12.1 lib/fog/openstack/requests/compute/get_address.rb
fog-1.12.0 lib/fog/openstack/requests/compute/get_address.rb
hpfog-0.0.20 lib/fog/openstack/requests/compute/get_address.rb
vagrant-shell-0.2.6 vendor/bundle/gems/fog-1.10.1/lib/fog/openstack/requests/compute/get_address.rb
vagrant-shell-0.2.5 vendor/bundle/gems/fog-1.10.1/lib/fog/openstack/requests/compute/get_address.rb
fog-nirvanix-1.8.2 lib/fog/openstack/requests/compute/get_address.rb
fog-1.11.1 lib/fog/openstack/requests/compute/get_address.rb