public class CreateServerRequest extends AbstractOpenstackRequest<org.openstack4j.model.compute.Server>
| Constructor and Description |
|---|
CreateServerRequest(OpenStackPoolDriverConfig accessConfig,
String serverName,
String flavorName,
String imageName,
String keyPair,
List<String> securityGroups,
com.google.common.base.Optional<String> userData,
Map<String,String> metadata)
Creates a new
CreateServerRequest. |
| Modifier and Type | Method and Description |
|---|---|
org.openstack4j.model.compute.Server |
doRequest(org.openstack4j.api.OSClient api)
Carries out the request and returns the response.
|
call, getAccessConfigpublic CreateServerRequest(OpenStackPoolDriverConfig accessConfig, String serverName, String flavorName, String imageName, String keyPair, List<String> securityGroups, com.google.common.base.Optional<String> userData, Map<String,String> metadata)
CreateServerRequest.accessConfig - Connection details for a particular OpenStack account.serverName - The name to assign to the new server.flavorName - The name of the machine type (flavor) to launch.imageName - The identifier of the machine image used to boot the machine.keyPair - The name of the key pair to use for the machine instance.securityGroups - The security group(s) to use for the new machine instance.userData - The (optional) user data (boot up script) used to
contextualize the started instance.metadata - Any meta data tags to assign to the new server.public org.openstack4j.model.compute.Server doRequest(org.openstack4j.api.OSClient api)
AbstractOpenstackRequestdoRequest in class AbstractOpenstackRequest<org.openstack4j.model.compute.Server>api - An authenticated OpenStack API client that is instructed to
operate against the configured region.Copyright © 2011–2015 elastisys. All rights reserved.