-
-
changeBackupSchedule
(
string $id, string $weekly, string $daily
)
-
This operation creates a new backup schedule or updates an existing backup schedule for
the specified server.
Return true in case of success, false in case of error.
$id is the ID of the server
$weekly, the day of the week for the backup (for instance "THURSDAY")
$daily, specify the hours for the backup (for instance "H_0400_0600")
-
-
changeServerName
(
string $id, string $name
)
-
Change the name of a server.
Return true in case of success, false in case of error.
$id is the ID of the server
$name is an optional parameter that specify the new name of the server
-
-
changeServerPassword
(
string $id, string $password
)
-
Change the admin password of a server.
Return true in case of success, false in case of error.
$id is the ID of the server
$password is an optional parameter that specify the new admin password of the server
-
-
confirmResizeServer
(
string $id
)
-
Confirm the resize of a server. During a resize operation, the original server is saved for a period of time to allow roll
back if there is a problem. Once the newly resized server is tested and has been confirmed
to be functioning properly, use this operation to confirm the resize. After confirmation,
the original server is removed and cannot be rolled back to. All resizes are automatically
confirmed after 24 hours if they are not explicitly confirmed or reverted.
Return true in case of success, false in case of error.
$id is Id of the server.
-
-
createImage
(
string $serverId,string $name
)
-
Create an image from a server.
Return a new instance of Zend_Service_Rackspace_Servers_Image.
In case of error the return is false.
$serverId is the Id of the server to use to create the image.
$name, is the name of image to create
-
-
createSharedIpGroup
(
string $name, string $serverId
)
-
This operation creates a new shared IP group. Please note, on a create request, the shared IP
group can be created empty or can be initially populated with a single server.
Return the shared IP group as instance of Zend_Service_Rackspace_Servers_SharedIpGroup
In case of error the return is false.
$name is the name of the shared IP group to create.
$serverId is the Id of the server.
-
-
createServer
(
array $data, $metadata=array(),$files=array()
)
-
Create a server with the attributes specified in $data. You can specify also
optional parameters: metadata and files.
Metadata is an array contains key/value of metadata related to the server and files is an array
contains the paths of some files to upload into the server. The syntax used for the uploading
of the files is 'serverPath' => 'localPath'.
Return a new instance of Zend_Service_Rackspace_Servers_Server.
In case of error the return is false.
$data contains the parameters for the server.
The required attributes to create a new server are:
-
name, contains the name of the server
-
flavorId, contains the flavor's Id to use
-
imageId, contains the image's Id to use
$metadata, contains the array of metadata information
$files, contains the path of the files to upload in the server
using the syntax 'serverPath' => 'localPath'.
-
-
disableBackupSchedule
(
string $id
)
-
Disable the backup of a server.
Return true in case of success, false in case of error.
$id is the Id of the server.
-
-
deleteImage
(
string $id
)
-
Delete a image.
Return true in case of success, false in case of error.
$id is the Id of the image.
-
-
deleteSharedIpGroup
(
string $id
)
-
Delete a shared IP group.
Return true in case of success, false in case of error.
$id is the Id of the shared IP group.
-
-
deleteServer
(
string $id
)
-
Delete a server.
Return true in case of success, false in case of error.
$id is the Id of the server.
-
-
getBackupSchedule
(
string $id
)
-
Return the backup schedule of a server. The return is an associative array with the following values: enabled, weekly, daily.
In case of error the return is false.
$id is the Id of the server.
-
-
getFlavor
(
string $flavorId
)
-
Return the information about a flavor. The return is an associative array with the following values: id, ram, disk, name.
In case of error the return is false.
$flavorId is the Id of the flavor.
-
-
getImage
(
string $id
)
-
Return an image as instance of Zend_Service_Rackspace_Servers_Image.
In case of error the return is false.
$id is the Id of the image.
-
-
getSharedIpGroup
(
string $id
)
-
Return the shared IP group as instance of Zend_Service_Rackspace_Servers_SharedIpGroup
In case of error the return is false.
$id is the Id of the shared IP group.
-
-
getServer
(
string $id
)
-
Return the server specified by the Id as instance of Zend_Service_Rackspace_Servers_Server.
In case of error the return is false.
$id is Id of the server.
-
-
getServerIp
(
string $id
)
-
Return the public and private IP addresses of a server.
Return an associative array contains the key 'public' and 'private' for the IP addresses.
In case of error the return is false.
$id is Id of the server.
-
-
getServerPrivateIp
(
string $id
)
-
Return the private IP addresses of the server.
Return an associative array contains the IP addresses.
In case of error the return is false.
$id is Id of the server.
-
-
getServerPublicIp
(
string $id
)
-
Return the public IP addresses of the server.
Return an associative array contains the IP addresses.
In case of error the return is false.
$id is Id of the server.
-
-
listFlavors
(
boolean $details=false
)
-
Return all the available flavors as associative array.
In case of error the return is false.
If $details is true return a detailed list, if is false return only the name and the Id of the flavor.
-
-
listImages
(
boolean $details=false
)
-
Return all the available images as instance of Zend_Service_Rackspace_Servers_ImageList
In case of error the return is false.
If $details is true return a detailed list, if is false return only the name and the Id of the Image.
-
-
listServer
(
boolean $details=false
)
-
Return all the available servers with a new instance of Zend_Service_Rackspace_Servers_ServerList.
In case of error the return is false.
If $details is true return a detailed list, if is false return only the name and the Id of the server.
-
-
listSharedIpGroups
(
boolean $details=false
)
-
Return all the shared IP groups as instance of Zend_Service_Rackspace_Servers_SharedIpGroupList
In case of error the return is false.
If $details is true return a detailed list, if is false return only the name and the Id of the shared IP group.
-
-
rebootServer
(
string $id, boolean $hard=false
)
-
Reboot a server.
Return true in case of success, false in case of error.
$id is Id of the server.
If $hard is false (default) the server is rebooted in soft mode.
That means the operating system is signaled to restart, which allows for a graceful shutdown of
all processes. If $hard is true the server is rebooted in hard mode.
A hard reboot is the equivalent of power cycling the server.
-
-
rebuildServer
(
string $id, string $imageId
)
-
Rebuild a server. The rebuild function removes all data on the server and replaces it with the specified image,
server's Id and IP addresses will remain the same.
Return true in case of success, false in case of error.
$id is Id of the server.
$imageId is the new Image Id of the server.
-
-
resizeServer
(
string $id, string $flavorId
)
-
Resize a server. The resize function converts an existing server to a different flavor, in essence, scaling the
server up or down. The original server is saved for a period of time to allow rollback if there
is a problem. All resizes should be tested and explicitly confirmed, at which time the original
server is removed. All resizes are automatically confirmed after 24 hours if they are not
explicitly confirmed or reverted.
Return true in case of success, false in case of error.
$id is Id of the server.
$flavorId is the new flavor Id of the server.
-
-
revertResizeServer
(
string $id
)
-
Revert the resize of a server. During a resize operation, the original server is saved for a period of time to allow for roll
back if there is a problem. If you determine there is a problem with a newly resized server,
use this operation to revert the resize and roll back to the original server. All resizes are
automatically confirmed after 24 hours if they have not already been confirmed explicitly or
reverted.
Return true in case of success, false in case of error.
$id is Id of the server.
-
-
shareIpAddress
(
string $id, string $ip, string $groupId, boolean $configure=true
)
-
Share an IP address for a server.
Return true in case of success, false in case of error.
$id is Id of the server.
$ip is the IP address to share.
$groupId is the group Id to use.
If $configure attribute is set to true, the server is configured
with the new address, though the address is not enabled. Note that configuring the server
does require a reboot.
-
-
unshareIpAddress
(
string $id, string $ip
)
-
Unshare an IP address for a server.
Return true in case of success, false in case of error.
$id is Id of the server.
$ip is the IP address to share.
-
-
updateServer
(
string $id,string $name=null,string $password=null
)
-
Change the name or/and the admin password of a server.
In case of error the return is false.
$id is the ID of the server
$name is an optional parameter that specify the new name of the server
$password is an optional parameter that specify the new admin password of the server