diff --git a/lib/ansible/modules/extras/cloud/amazon/ec2_vpc_igw.py b/lib/ansible/modules/extras/cloud/amazon/ec2_vpc_igw.py index 63be48248ef..5218bff5e6e 100644 --- a/lib/ansible/modules/extras/cloud/amazon/ec2_vpc_igw.py +++ b/lib/ansible/modules/extras/cloud/amazon/ec2_vpc_igw.py @@ -133,7 +133,7 @@ def main(): if region: try: - connection = connect_to_aws(boto.ec2, region, **aws_connect_params) + connection = connect_to_aws(boto.vpc, region, **aws_connect_params) except (boto.exception.NoAuthHandlerFound, StandardError), e: module.fail_json(msg=str(e)) else: