Skip to content
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

Not having success #3

Open
ckonkel opened this issue Feb 26, 2016 · 1 comment
Open

Not having success #3

ckonkel opened this issue Feb 26, 2016 · 1 comment

Comments

@ckonkel
Copy link

ckonkel commented Feb 26, 2016

If this can do what I think you say it does ...it will be a godsend!

On a Mac
Connected to VPC...
All dependencies installed...

This is the result ... any insight?

A-CKONKEL-MBPR:ectou-export-master ckonkel$ ./export.py --ami-name amzn-ami-hvm-2015.09.1.x86_64-gp2
get ec2.Image(id='ami-60b6c60a')
create ec2.KeyPair(name='ectou-export-1eb1f249-cb31-48fa-9f4a-966615c16c13')
create ec2.SecurityGroup(id='sg-8e7e6fe4')
exception An error occurred (InvalidParameter) when calling the RunInstances operation: The AssociatePublicIpAddress parameter is only supported for VPC launches.
delete ec2.SecurityGroup(id='sg-8e7e6fe4')
delete ec2.KeyPair(name='ectou-export-1eb1f249-cb31-48fa-9f4a-966615c16c13')
Traceback (most recent call last):
File "./export.py", line 326, in
main()
File "./export.py", line 292, in main
AssociatePublicIpAddress=True,
File "/Library/Python/2.7/site-packages/boto3/resources/factory.py", line 456, in do_action
response = action(self, _args, *_kwargs)
File "/Library/Python/2.7/site-packages/boto3/resources/action.py", line 83, in call
response = getattr(parent.meta.client, operation_name)(**params)
File "/Library/Python/2.7/site-packages/botocore/client.py", line 301, in _api_call
return self._make_api_call(operation_name, kwargs)
File "/Library/Python/2.7/site-packages/botocore/client.py", line 398, in _make_api_call
raise ClientError(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (InvalidParameter) when calling the RunInstances operation: The AssociatePublicIpAddress parameter is only supported for VPC launches.
A-CKONKEL-MBPR:ectou-export-master ckonkel$ ./export.py --ami-name amzn-ami-hvm-2015.09.1.x86_64-gp2
get ec2.Image(id='ami-60b6c60a')
create ec2.KeyPair(name='ectou-export-94984eb4-8a6f-4718-b2c6-379b9b36db26')
create ec2.SecurityGroup(id='sg-087c6d62')
exception An error occurred (InvalidParameter) when calling the RunInstances operation: The AssociatePublicIpAddress parameter is only supported for VPC launches.
delete ec2.SecurityGroup(id='sg-087c6d62')
delete ec2.KeyPair(name='ectou-export-94984eb4-8a6f-4718-b2c6-379b9b36db26')
Traceback (most recent call last):
File "./export.py", line 326, in
main()
File "./export.py", line 292, in main
AssociatePublicIpAddress=True,
File "/Library/Python/2.7/site-packages/boto3/resources/factory.py", line 456, in do_action
response = action(self, _args, *_kwargs)
File "/Library/Python/2.7/site-packages/boto3/resources/action.py", line 83, in call
response = getattr(parent.meta.client, operation_name)(**params)
File "/Library/Python/2.7/site-packages/botocore/client.py", line 301, in _api_call
return self._make_api_call(operation_name, kwargs)
File "/Library/Python/2.7/site-packages/botocore/client.py", line 398, in _make_api_call
raise ClientError(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (InvalidParameter) when calling the RunInstances operation: The AssociatePublicIpAddress parameter is only supported for VPC launches.

@jjpersch
Copy link
Contributor

jjpersch commented Jun 7, 2016

Try using the --vpc-name or --vpc-id arguments.

If those are not specified, it will assume the account has a default VPC, which will not be the case for any account that supports Classic instances.

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

No branches or pull requests

2 participants