Sha256: 5f21cdbba022b2e7c316c91f7c6c7806699f6a5dd0f97019958b18d85f009c96

Contents?: true

Size: 812 Bytes

Versions: 14

Compression:

Stored size: 812 Bytes

Contents

module Fog
  module Compute
    class OpenStack
      class Real
        # Remove an IP address.
        #
        # === Parameters
        # * server_id <~String> - The ID of the server in which to remove an IP from.
        # * address <~String> - The IP address to be removed.
        # === Returns
        # * success <~Boolean>
        def remove_fixed_ip(server_id, address)
          body = {
            'removeFixedIp' => {
              'address' => address
            }
          }
          server_action(server_id, body).status == 202
        end # def remove_fixed_ip
      end # class Real

      class Mock
        def remove_fixed_ip(_server_id, _address)
          true
        end # def remove_fixed_ip
      end # class Mock
    end # class OpenStack
  end # module Compute
end # module Fog

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
fog-openstack-0.1.25 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.24 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.23 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.22 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.21 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.20 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.19 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.18 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.17 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.15 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.14 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.13 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.12 lib/fog/compute/openstack/requests/remove_fixed_ip.rb
fog-openstack-0.1.11 lib/fog/compute/openstack/requests/remove_fixed_ip.rb