Class Fog::Compute::HP::Real
In: lib/fog/hp/requests/compute/delete_security_group.rb
lib/fog/hp/requests/compute/delete_server.rb
lib/fog/hp/requests/compute/disassociate_address.rb
lib/fog/hp/requests/compute/get_address.rb
lib/fog/hp/requests/compute/list_images.rb
lib/fog/hp/requests/compute/get_flavor_details.rb
lib/fog/hp/requests/compute/rebuild_server.rb
lib/fog/hp/requests/compute/get_image_details.rb
lib/fog/hp/requests/compute/delete_key_pair.rb
lib/fog/hp/requests/compute/list_addresses.rb
lib/fog/hp/requests/compute/get_server_details.rb
lib/fog/hp/requests/compute/create_security_group_rule.rb
lib/fog/hp/requests/compute/confirm_resized_server.rb
lib/fog/hp/requests/compute/release_address.rb
lib/fog/hp/requests/compute/update_server.rb
lib/fog/hp/requests/compute/list_server_addresses.rb
lib/fog/hp/requests/compute/create_key_pair.rb
lib/fog/hp/requests/compute/allocate_address.rb
lib/fog/hp/requests/compute/delete_security_group_rule.rb
lib/fog/hp/requests/compute/associate_address.rb
lib/fog/hp/requests/compute/reboot_server.rb
lib/fog/hp/requests/compute/list_server_public_addresses.rb
lib/fog/hp/requests/compute/list_images_detail.rb
lib/fog/hp/requests/compute/create_image.rb
lib/fog/hp/requests/compute/create_security_group.rb
lib/fog/hp/requests/compute/list_servers.rb
lib/fog/hp/requests/compute/list_flavors.rb
lib/fog/hp/requests/compute/change_password_server.rb
lib/fog/hp/requests/compute/list_security_groups.rb
lib/fog/hp/requests/compute/revert_resized_server.rb
lib/fog/hp/requests/compute/list_flavors_detail.rb
lib/fog/hp/requests/compute/server_action.rb
lib/fog/hp/requests/compute/get_security_group.rb
lib/fog/hp/requests/compute/list_key_pairs.rb
lib/fog/hp/requests/compute/list_servers_detail.rb
lib/fog/hp/requests/compute/resize_server.rb
lib/fog/hp/requests/compute/list_server_private_addresses.rb
lib/fog/hp/requests/compute/delete_image.rb
lib/fog/hp/requests/compute/create_server.rb
lib/fog/hp/compute.rb
Parent: Object

Methods

Public Class methods

Public Instance methods

Acquires a floating IP address

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘floating_ip’<~Hash> -
        • ‘id’<~Integer> - Id of the address
        • ‘ip’<~String> - Floating IP of the address
        • ‘instance_id’<~String> - Id of the associated server instance
        • ‘fixed_ip’<~String> - Fixed IP of the address

Associate a floating IP address with existing server

Parameters

  • server_id<~Integer> - Id of server to associate IP with
  • ip_address<~String> - IP address to associate with the server

Confirm resizing

Parameters

  • server_id<~Integer> - Id of server to confirm

Create an image from an existing server

Parameters

  • server_id<~Integer> - Id of server to create image from
  • name<~String> - Name of the image
  • metadata<~Hash> - A hash of metadata options
    • ‘ImageType’<~String> - type of the image i.e. Gold
    • ‘ImageVersion’<~String> - version of the image i.e. 2.0

Returns

Does not return a response body.

Create a new keypair

Parameters

  • key_name<~String> - Name of the keypair
  • public_key<~String> - The public key for the keypair

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘keypair’<~Hash> - The keypair data
        • ‘public_key’<~String> - The public key for the keypair
        • ‘private_key’<~String> - The private key for the keypair
        • ‘user_id’<~String> - The user id
        • ‘fingerprint’<~String> - SHA-1 digest of DER encoded private key
        • ‘name’<~String> - Name of key

Openstack API Reference

Create a new security group

Parameters

  • ‘name’<~String> - name of the security group
  • ‘description’<~String> - description of the security group

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘security_group’<~Array>:
      • ‘rules’<~Array>: - array of security group rules
        • ‘id’<~Integer> - id of the security group rule
        • ‘from_port’<~Integer> - start port for rule i.e. 22 (or -1 for ICMP wildcard)
        • ‘to_port’<~Integer> - end port for rule i.e. 22 (or -1 for ICMP wildcard)
        • ‘ip_protocol’<~String> - ip protocol for rule, must be in [‘tcp’, ‘udp’, ‘icmp’]
        • ‘group’<~Hash>:
           * Undefined
          
        • ‘parent_group_id’<~Integer> - parent group id
        • ‘ip_range’<~Hash>:
          • ‘cidr’<~String> - ip range address i.e. ‘0.0.0.0/0‘
      • ‘id’<~Integer> - id of the security group
      • ‘name’<~String> - name of the security group
      • ‘description’<~String> - description of the security group
      • ‘tenant_id’<~String> - tenant id of the user

Openstack API Reference

Create a new security group rule and attach it to a security group

Parameters

  * 'parent_group_id'<~Integer> - id of the parent security group
  * 'ip_protocol'<~String> - ip protocol for rule, must be in ['tcp', 'udp', 'icmp']
  * 'from_port'<~Integer> - start port for rule i.e. 22 (or -1 for ICMP wildcard)
  * 'to_port'<~Integer> - end port for rule i.e. 22 (or -1 for ICMP wildcard)
  * 'cidr'<~String> - ip range address i.e. '0.0.0.0/0'
  * 'group_id'<~Integer> - id of the security group to which this rule applies

Returns

  • response<~Excon::Response>:

Openstack API Reference

Create a new server

Parameters

  • name<~String> - Name of server
  • flavor_id<~Integer> - Id of flavor for server
  • image_id<~Integer> - Id of image for server
  • options<~Hash>:
    • ‘metadata’<~Hash> - Up to 5 key value pairs containing 255 bytes of info
    • ‘min_count’<~Integer> - Number of servers to create. Defaults to 1.
    • ‘max_count’<~Integer> - Max. number of servers to create. Defaults to being equal to min_count.
    • ‘key_name’<~String> - Name of keypair to be used
    • ‘security_groups’<~Array> - one or more security groups to be used
    • ‘availability_zone’<~String> - the availability zone to be used
    • ‘personality’<~Array>: Up to 5 files to customize server
      • file<~Hash>:
        • ‘contents’<~String> - Contents of file (10kb total of contents)
        • ‘path’<~String> - Path to file (255 bytes total of path strings)
    • ‘accessIPv4’<~String> - IPv4 IP address
    • ‘accessIPv6’<~String> - IPv6 IP address

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘server’<~Hash>:
      • ‘addresses’<~Hash>:
        • ‘public’<~Array> - public address strings
        • ‘private’<~Array> - private address strings
      • ‘adminPass’<~String> - Admin password for server
      • ‘flavorId’<~Integer> - Id of servers current flavor
      • ‘hostId’<~String>
      • ‘id’<~Integer> - Id of server
      • ‘imageId’<~Integer> - Id of image used to boot server
      • ‘metadata’<~Hash> - metadata
      • ‘name’<~String> - Name of server
      • ‘progress’<~Integer> - Progress through current status
      • ‘status’<~String> - Current server status

Delete an image

Parameters

  • image_id<~Integer> - Id of image to delete

Delete a keypair

Parameters

  • key_name<~String> - Name of the keypair to delete

Delete a security group

Parameters

  • id<~Integer> - Id of the security group to delete

Openstack API Reference

Delete a security group rule

Parameters

  • id<~Integer> - id of the security group rule to delete

Openstack API Reference

Delete an existing server

Parameters

  • id<~Integer> - Id of server to delete

Disassociate a floating IP address with existing server

Parameters

  • server_id<~Integer> - Id of server to associate IP with
  • ip_address<~String> - IP address to associate with the server

Get details about an existing floating IP address

Parameters

  • ‘address_id’<~Integer> - Id of floating IP address get details for

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘floating_ip’<~Hash> -
        • ‘id’<~Integer> - Id of the address
        • ‘ip’<~String> - Floating IP of the address
        • ‘instance_id’<~String> - Id of the associated server instance
        • ‘fixed_ip’<~String> - Fixed IP of the address

Get details for flavor by id

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘id’<~Integer> - Id of the flavor
      • ‘name’<~String> - Name of the flavor
      • ‘ram’<~Integer> - Amount of ram for the flavor
      • ‘disk’<~Integer> - Amount of diskspace for the flavor

Get details for image by id

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘id’<~Integer> - Id of the image
      • ‘name’<~String> - Name of the image
      • ‘serverId’<~Integer> - Id of server image was created from
      • ‘status’<~Integer> - Status of image
      • ‘updated’<~String> - Timestamp of last update

Get details about a security group

Parameters

  • ‘security_group_id’<~Integer> - Id of security group to get details for

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘security_group’<~Array>:
      • ‘rules’<~Array>: - array of security group rules
        • ‘id’<~Integer> - id of the security group rule
        • ‘from_port’<~Integer> - start port for rule i.e. 22 (or -1 for ICMP wildcard)
        • ‘to_port’<~Integer> - end port for rule i.e. 22 (or -1 for ICMP wildcard)
        • ‘ip_protocol’<~String> - ip protocol for rule, must be in [‘tcp’, ‘udp’, ‘icmp’]
        • ‘group’<~Hash>:
           * Undefined
          
        • ‘parent_group_id’<~Integer> - parent group id
        • ‘ip_range’<~Hash>:
          • ‘cidr’<~String> - ip range address i.e. ‘0.0.0.0/0‘
      • ‘id’<~Integer> - id of the security group
      • ‘name’<~String> - name of the security group
      • ‘description’<~String> - description of the security group
      • ‘tenant_id’<~String> - tenant id of the user

Openstack API Reference

Get details about a server

Parameters

  • server_id<~Integer> - Id of server to get details for

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘server’<~Hash>:
      • ‘addresses’<~Hash>:
        • ‘public’<~Array> - public address strings
        • ‘private’<~Array> - private address strings
      • ‘flavorId’<~Integer> - Id of servers current flavor
      • ‘hostId’<~String>
      • ‘id’<~Integer> - Id of server
      • ‘imageId’<~Integer> - Id of image used to boot server
      • ‘metadata’<~Hash> - metadata
      • ‘name<~String> - Name of server
      • ‘progress’<~Integer> - Progress through current status
      • ‘status’<~String> - Current server status

List all floating IP addresses

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘floating_ips’<~Array> -
        • ‘id’<~Integer> - Id of the address
        • ‘ip’<~String> - Floating IP of the address
        • ‘instance_id’<~String> - Id of the associated server instance
        • ‘fixed_ip’<~String> - Fixed IP of the address

List all flavors (IDs and names only)

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘id’<~Integer> - Id of the flavor
      • ‘name’<~String> - Name of the flavor

List all flavors

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘id’<~Integer> - Id of the flavor
      • ‘name’<~String> - Name of the flavor
      • ‘ram’<~Integer> - Amount of ram for the flavor
      • ‘disk’<~Integer> - Amount of diskspace for the flavor

List all images (IDs and names only)

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘id’<~Integer> - Id of the image
      • ‘name’<~String> - Name of the image

List all images

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘id’<~Integer> - Id of the image
      • ‘name’<~String> - Name of the image
      • ‘updated’<~String> - Last update timestamp for image
      • ‘created’<~String> - Creation timestamp for image
      • ‘status’<~String> - Status of image

List all key pairs

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘keypairs’<~Array>:
        • ‘keypair’<~Hash>:
          • ‘public_key’<~String> - Public portion of the key
          • ‘name’<~String> - Name of the key
          • ‘fingerprint’<~String> - Fingerprint of the key

Openstack API Reference

List all security groups

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘security_groups’<~Array>:
      • ‘rules’<~Array>: - array of security group rules
        • ‘id’<~Integer> - id of the security group rule
        • ‘from_port’<~Integer> - start port for rule i.e. 22 (or -1 for ICMP wildcard)
        • ‘to_port’<~Integer> - end port for rule i.e. 22 (or -1 for ICMP wildcard)
        • ‘ip_protocol’<~String> - ip protocol for rule, must be in [‘tcp’, ‘udp’, ‘icmp’]
        • ‘group’<~Hash>:
           * Undefined
          
        • ‘parent_group_id’<~Integer> - parent group id
        • ‘ip_range’<~Hash>:
          • ‘cidr’<~String> - ip range address i.e. ‘0.0.0.0/0‘
      • ‘id’<~Integer> - id of the security group
      • ‘name’<~String> - name of the security group
      • ‘description’<~String> - description of the security group
      • ‘tenant_id’<~String> - tenant id of the user

Openstack API Reference

List all server addresses

Parameters

  • server_id<~Integer> - Id of server to list addresses for

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘addresses’<~Hash>:
      • ‘novanet_7’:<~Array> - The network name can change based on setup

List private server addresses

Parameters

  • server_id<~Integer> - Id of server to list addresses for
  • network_name<~String> - The name of the network name i.e. public, private or custom name

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘private’<~Array> - Private ip addresses

List public server addresses

Parameters

  • server_id<~Integer> - Id of server to list addresses for
  • network_name<~String> - The name of the network name i.e. public, private or custom name

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
      • ‘public’<~Array> - Public ip addresses

List all servers (IDs and names only)

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘servers’<~Array>:
      • ‘id’<~Integer> - Id of server
      • ‘name<~String> - Name of server

List all servers details

Returns

  • response<~Excon::Response>:
    • body<~Hash>:
    • ‘servers’<~Array>:
      • ‘id’<~Integer> - Id of server
      • ‘name<~String> - Name of server
      • ‘imageId’<~Integer> - Id of image used to boot server
      • ‘flavorId’<~Integer> - Id of servers current flavor
      • ‘hostId’<~String>
      • ‘status’<~String> - Current server status
      • ‘progress’<~Integer> - Progress through current status
      • ‘addresses’<~Hash>:
        • ‘public’<~Array> - public address strings
        • ‘private’<~Array> - private address strings
      • ‘metadata’<~Hash> - metadata

Reboot an existing server

Parameters

  • server_id<~Integer> - Id of server to reboot
  • type<~String> - Type of reboot, must be in [‘HARD’, ‘SOFT’]

Release an existing floating IP address

Parameters

  • id<~Integer> - Id of floating IP address to delete

Reboot an existing server

Parameters

  • server_id<~Integer> - Id of server to resize
  • size<~String> - new size. call list_flavors to get available flavors

Revert resizing

Parameters

  • server_id<~Integer> - Id of server to revert

Server actions for an existing server

Parameters

  • server_id<~Integer> - Id of server to reboot
  • body<~.to_json object> - Body of the request, describes the action (see reboot_server as an example)
  • expect<~Integer> - expected return, 202 except for confirm resize (204)

Update an existing server

Parameters

# server_id<~Integer> - Id of server to update

  • options<~Hash>:
    • adminPass<~String> - New admin password for server
    • name<~String> - New name for server

[Validate]