From fdce9ccfa02e707faa4d0ca504a658429734d490 Mon Sep 17 00:00:00 2001 From: Floran Brutel Date: Fri, 15 May 2015 11:50:11 +0200 Subject: [PATCH] Fix samples for create server from bootable volume --- samples/Compute/create_server_from_bootable_volume.php | 3 ++- ..._server_from_bootable_volume_delete_on_termination.php | 8 +++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/samples/Compute/create_server_from_bootable_volume.php b/samples/Compute/create_server_from_bootable_volume.php index 141a94f12..3be223a90 100644 --- a/samples/Compute/create_server_from_bootable_volume.php +++ b/samples/Compute/create_server_from_bootable_volume.php @@ -47,7 +47,8 @@ $response = $server->create(array( 'name' => '{serverName}', 'imageId' => '{imageId}', - 'flavorId' => '{flavorId}' + 'flavorId' => '{flavorId}', + 'volume' => $bootableVolume )); } catch (BadResponseException $e) { echo $e->getResponse(); diff --git a/samples/Compute/create_server_from_bootable_volume_delete_on_termination.php b/samples/Compute/create_server_from_bootable_volume_delete_on_termination.php index 20457105b..3b6425a6a 100644 --- a/samples/Compute/create_server_from_bootable_volume_delete_on_termination.php +++ b/samples/Compute/create_server_from_bootable_volume_delete_on_termination.php @@ -47,9 +47,11 @@ // list_images.php scripts. try { $response = $server->create(array( - 'name' => '{serverName}', - 'imageId' => '{imageId}', - 'flavorId' => '{flavorId}' + 'name' => '{serverName}', + 'imageId' => '{imageId}', + 'flavorId' => '{flavorId}', + 'volume' => $bootableVolume, + 'volumeDeleteOnTermination' => true )); } catch (BadResponseException $e) { echo $e->getResponse();