Service
class Service extends AbstractService
Compute v2 service for OpenStack.
Traits
Methods
Create a new server resource. This operation will provision a new virtual machine on a host chosen by your service API.
List servers.
Retrieve a server object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Server::retrieve}. For example:
List flavors.
Retrieve a flavor object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Flavor::retrieve}.
Create a new flavor resource.
List images.
Retrieve an image object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Image::retrieve}.
List key pairs.
Create or import keypair
Get keypair
Shows summary statistics for all hypervisors over all compute nodes.
List hypervisors.
Shows details for a given hypervisor.
Retrieve a host object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Host::retrieve}. For example:
List AZs
Shows A Quota for a tenant
Details
createServer(array $options)
Create a new server resource. This operation will provision a new virtual machine on a host chosen by your service API.
getServer(array $options = array())
Retrieve a server object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Server::retrieve}. For example:
$server = $service->getServer(['id' => '{serverId}']);
getFlavor(array $options = array())
Retrieve a flavor object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Flavor::retrieve}.
getImage(array $options = array())
Retrieve an image object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Image::retrieve}.
listHypervisors(bool $detailed = false, array $options = array(), callable $mapFn = null)
List hypervisors.
getHost(array $options = array())
Retrieve a host object without calling the remote API. Any values provided in the array will populate the empty object, allowing you greater control without the expense of network transactions. To call the remote API and have the response populate the object, call {see Host::retrieve}. For example:
$server = $service->getHost(['name' => '{name}']);