Skip to content

Add eu-central-1 to EC2 drivers#545

Closed
JamesGuthrie wants to merge 1 commit intoapache:trunkfrom
JamesGuthrie:ec2-eu-central
Closed

Add eu-central-1 to EC2 drivers#545
JamesGuthrie wants to merge 1 commit intoapache:trunkfrom
JamesGuthrie:ec2-eu-central

Conversation

@JamesGuthrie
Copy link
Copy Markdown
Contributor

Signed-off-by: James Guthrie james@prodigi.ch

Signed-off-by: James Guthrie <james@prodigi.ch>
@ralphbean
Copy link
Copy Markdown

Why did this get closed?

@JamesGuthrie
Copy link
Copy Markdown
Contributor Author

Because it's outdated. Unfortunately the documentation hasn't been updated to reflect the change in the API though, and I only realised after making the PR that the documentation is outdated and my PR redundant.

The change is (mentioned here) is:

Deprecate the following EC2 provider constants: EC2_US_EAST, EC2_EU, EC2_EU_WEST, EC2_AP_SOUTHEAST, EC2_AP_NORTHEAST, EC2_US_WEST_OREGON, EC2_SA_EAST, EC2_SA_EAST and replace it with a new EC2 constant. Driver referenced by this new constant now takes a “region” argument which dictates to which region to connect.

So the following example (lifted from the docs):

cls = get_driver(Provider.EC2_US_WEST)
driver = cls('temporary access key', 'temporary secret key', token='temporary session token')

becomes:

cls = get_driver(Provider.EC2)
driver = cls("auth key", "auth secret", token="token", region="us-west-1")

So the driver type is no longer used to determine the location which the driver connects to. Instead, if you specify a valid region, that is the region it connects to. Valid regions are:

  • eu-west-1
  • sa-east-1
  • ap-southeast-2
  • us-west-1
  • us-east-1
  • ap-southeast-1
  • ap-northeast-1
  • us-gov-west-1
  • eu-central-1
  • us-west-2

@JamesGuthrie
Copy link
Copy Markdown
Contributor Author

I've opened #606 to fix the docs.

@ralphbean
Copy link
Copy Markdown

Thanks @JamesGuthrie. I wandered down the same path you did!

@JamesGuthrie
Copy link
Copy Markdown
Contributor Author

No problem! Hopefully you will be the last to do so.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants