Return-Path: X-Original-To: apmail-libcloud-notifications-archive@www.apache.org Delivered-To: apmail-libcloud-notifications-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 13CB710D27 for ; Mon, 7 Apr 2014 15:08:09 +0000 (UTC) Received: (qmail 32472 invoked by uid 500); 7 Apr 2014 15:08:08 -0000 Delivered-To: apmail-libcloud-notifications-archive@libcloud.apache.org Received: (qmail 32414 invoked by uid 500); 7 Apr 2014 15:08:03 -0000 Mailing-List: contact notifications-help@libcloud.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@libcloud.apache.org Delivered-To: mailing list notifications@libcloud.apache.org Received: (qmail 32407 invoked by uid 500); 7 Apr 2014 15:08:01 -0000 Delivered-To: apmail-libcloud-commits@libcloud.apache.org Received: (qmail 32402 invoked by uid 99); 7 Apr 2014 15:08:01 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 07 Apr 2014 15:08:01 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id DB57594C725; Mon, 7 Apr 2014 15:08:00 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: tomaz@apache.org To: commits@libcloud.apache.org Message-Id: <42a91ff8cfe84d0eac1d88f0a77d436b@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: git commit: Allow user to pass ex_ebs_optimized argument to the create_node method in the EC2 driver. Date: Mon, 7 Apr 2014 15:08:00 +0000 (UTC) Repository: libcloud Updated Branches: refs/heads/trunk e780066b2 -> 502846370 Allow user to pass ex_ebs_optimized argument to the create_node method in the EC2 driver. Closes #272 Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/50284637 Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/50284637 Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/50284637 Branch: refs/heads/trunk Commit: 502846370576fa3b11ad0cff7f4ad72b3743be73 Parents: e780066 Author: Tomaz Muraus Authored: Mon Apr 7 08:55:07 2014 -0600 Committer: Tomaz Muraus Committed: Mon Apr 7 08:56:58 2014 -0600 ---------------------------------------------------------------------- CHANGES.rst | 5 +++++ libcloud/compute/drivers/ec2.py | 6 ++++++ 2 files changed, 11 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/libcloud/blob/50284637/CHANGES.rst ---------------------------------------------------------------------- diff --git a/CHANGES.rst b/CHANGES.rst index b98df33..616656a 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -76,6 +76,11 @@ Compute - Add ex_revoke_security_group_ingress method to the CloudStack driver. [Chris DeRamus, Tomaz Muraus] +- Allow user to pass ex_ebs_optimized argument to the create_node method + in the EC2 driver. + (GITHUB-272) + [zerthimon] + Load Balancer ~~~~~~~~~~~~~ http://git-wip-us.apache.org/repos/asf/libcloud/blob/50284637/libcloud/compute/drivers/ec2.py ---------------------------------------------------------------------- diff --git a/libcloud/compute/drivers/ec2.py b/libcloud/compute/drivers/ec2.py index 4d75fa3..bac7f8d 100644 --- a/libcloud/compute/drivers/ec2.py +++ b/libcloud/compute/drivers/ec2.py @@ -1362,6 +1362,9 @@ class BaseEC2NodeDriver(NodeDriver): :keyword ex_iamprofile: Name or ARN of IAM profile :type ex_iamprofile: ``str`` + + :keyword ex_ebs_optimized: EBS-Optimized if True + :type ex_ebs_optimized: ``bool`` """ image = kwargs["image"] size = kwargs["size"] @@ -1430,6 +1433,9 @@ class BaseEC2NodeDriver(NodeDriver): else: params['IamInstanceProfile.Name'] = kwargs['ex_iamprofile'] + if 'ex_ebs_optimized' in kwargs: + params['EbsOptimized'] = kwargs['ex_ebs_optimized'] + object = self.connection.request(self.path, params=params).object nodes = self._to_nodes(object, 'instancesSet/item')