New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LIBCLOUD-525: Add VPC lifecycle support into the EC2 driver. This PR inc... #255

Closed
wants to merge 2 commits into
base: trunk
from

Conversation

Projects
None yet
2 participants
@cderamus
Contributor

cderamus commented Mar 2, 2014

...ludes the ability to describe, create, delete, attach and detach VPC Internet gateways.

Chris DeRamus
LIBCLOUD-525: Add VPC lifecycle support into the EC2 driver. This PR …
…includes the ability to describe, create, delete, attach and detach VPC Internet gateways.
@Kami

View changes

Show outdated Hide outdated libcloud/compute/drivers/ec2.py
@@ -1171,6 +1171,24 @@ def __repr__(self):
% (self.ip, self.domain, self.instance_id))
class VPCInternetGateway(Node):

This comment has been minimized.

@Kami

Kami Mar 2, 2014

Member

Hm, this probably shouldn't inherit from Node, right?

@Kami

Kami Mar 2, 2014

Member

Hm, this probably shouldn't inherit from Node, right?

This comment has been minimized.

@cderamus

cderamus Mar 2, 2014

Contributor

Correct.

@cderamus

cderamus Mar 2, 2014

Contributor

Correct.

@Kami

View changes

Show outdated Hide outdated libcloud/compute/drivers/ec2.py
def ex_detach_internet_gateway(self, gateway, network):
"""
Detach a Internet gateway to a VPC

This comment has been minimized.

@Kami

Kami Mar 2, 2014

Member

to a VPC = from a VPC :)

@Kami

Kami Mar 2, 2014

Member

to a VPC = from a VPC :)

@Kami

View changes

Show outdated Hide outdated libcloud/compute/drivers/ec2.py
# If there's no attachment state, let's
# set it to available
if state is None:

This comment has been minimized.

@Kami

Kami Mar 2, 2014

Member

IIRC, findtext will return empty string ('') by default if the matching item is not found. This means we will never get into this branch.

You can pass no_text_value='' to findtext function, or even better, just do if not state.

@Kami

Kami Mar 2, 2014

Member

IIRC, findtext will return empty string ('') by default if the matching item is not found. This means we will never get into this branch.

You can pass no_text_value='' to findtext function, or even better, just do if not state.

@Kami

This comment has been minimized.

Show comment
Hide comment
@Kami

Kami Mar 2, 2014

Member

Merged into trunk.

Thanks.

Member

Kami commented Mar 2, 2014

Merged into trunk.

Thanks.

@asfgit asfgit closed this in 0cdc81f Mar 2, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment