provider/aws: Add env default for AWS_ACCOUNT_ID in VPC Peering connection

This commit is contained in:
Clint Shryock 2015-03-10 14:44:07 -05:00
parent d2c6ae0741
commit fe293f909e
2 changed files with 5 additions and 5 deletions

View File

@ -22,6 +22,7 @@ func resourceAwsVpcPeeringConnection() *schema.Resource {
Type: schema.TypeString, Type: schema.TypeString,
Required: true, Required: true,
ForceNew: true, ForceNew: true,
DefaultFunc: schema.EnvDefaultFunc("AWS_ACCOUNT_ID", nil),
}, },
"peer_vpc_id": &schema.Schema{ "peer_vpc_id": &schema.Schema{
Type: schema.TypeString, Type: schema.TypeString,

View File

@ -68,11 +68,10 @@ resource "aws_vpc" "foo" {
} }
resource "aws_vpc" "bar" { resource "aws_vpc" "bar" {
cidr_block = "10.0.1.0/16" cidr_block = "10.1.0.0/16"
} }
resource "aws_vpc_peering_connection" "foo" { resource "aws_vpc_peering_connection" "foo" {
peer_owner_id = "12345"
vpc_id = "${aws_vpc.foo.id}" vpc_id = "${aws_vpc.foo.id}"
peer_vpc_id = "${aws_vpc.bar.id}" peer_vpc_id = "${aws_vpc.bar.id}"
} }