You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by er...@apache.org on 2014/12/09 19:07:05 UTC
libcloud git commit: [google compute] fix ex_disk_auto_delete for
create_node() Closes #412
Repository: libcloud
Updated Branches:
refs/heads/trunk 5b2478012 -> bf703e60c
[google compute] fix ex_disk_auto_delete for create_node()
Closes #412
Signed-off-by: Eric Johnson <er...@google.com>
Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/bf703e60
Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/bf703e60
Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/bf703e60
Branch: refs/heads/trunk
Commit: bf703e60c58c1ec0d56fd27fdb25daad72892f4e
Parents: 5b24780
Author: Igor Bogomazov <ib...@griddynamics.com>
Authored: Thu Dec 4 14:44:49 2014 +0300
Committer: Eric Johnson <er...@google.com>
Committed: Tue Dec 9 18:05:49 2014 +0000
----------------------------------------------------------------------
CHANGES.rst | 4 ++++
libcloud/compute/drivers/gce.py | 3 +++
2 files changed, 7 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/libcloud/blob/bf703e60/CHANGES.rst
----------------------------------------------------------------------
diff --git a/CHANGES.rst b/CHANGES.rst
index cc5f7a4..4e96e37 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -16,6 +16,10 @@ General
Compute
~~~~~~~
+- Fix boot disk auto_delete in GCE driver.
+ (GITHUB-412)
+ [Igor Bogomazov]
+
- Add Routes to GCE driver.
(GITHUB-410)
[Eric Johnson]
http://git-wip-us.apache.org/repos/asf/libcloud/blob/bf703e60/libcloud/compute/drivers/gce.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/drivers/gce.py b/libcloud/compute/drivers/gce.py
index c8bbeca..31b11c8 100644
--- a/libcloud/compute/drivers/gce.py
+++ b/libcloud/compute/drivers/gce.py
@@ -3256,11 +3256,14 @@ class GCENodeDriver(NodeDriver):
node_data['serviceAccounts'] = set_scopes
if boot_disk:
+ if not isinstance(ex_disk_auto_delete, bool):
+ raise ValueError("ex_disk_auto_delete field is not a bool.")
disks = [{'kind': 'compute#attachedDisk',
'boot': True,
'type': 'PERSISTENT',
'mode': 'READ_WRITE',
'deviceName': boot_disk.name,
+ 'autoDelete': ex_disk_auto_delete,
'zone': boot_disk.extra['zone'].extra['selfLink'],
'source': boot_disk.extra['selfLink']}]
node_data['disks'] = disks