Skip to content

Commit

Permalink
Merge pull request #3436 from justinsb/mock_aws_should_use_same_provi…
Browse files Browse the repository at this point in the history
…derid

Automatic merge from submit-queue. .

AWS mock provider should use the AWS cloudprovider id
  • Loading branch information
Kubernetes Submit Queue authored Sep 24, 2017
2 parents a7fcced + bde0c46 commit e97efcc
Show file tree
Hide file tree
Showing 14 changed files with 53 additions and 1 deletion.
4 changes: 4 additions & 0 deletions tests/integration/complex/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ output "vpc_id" {
value = "${aws_vpc.complex-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_group" "master-us-test-1a-masters-complex-example-com" {
name = "master-us-test-1a.masters.complex.example.com"
launch_configuration = "${aws_launch_configuration.master-us-test-1a-masters-complex-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/ha/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ output "vpc_id" {
value = "${aws_vpc.ha-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_group" "master-us-test-1a-masters-ha-example-com" {
name = "master-us-test-1a.masters.ha.example.com"
launch_configuration = "${aws_launch_configuration.master-us-test-1a-masters-ha-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/minimal-141/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ output "vpc_id" {
value = "${aws_vpc.minimal-141-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_group" "master-us-test-1a-masters-minimal-141-example-com" {
name = "master-us-test-1a.masters.minimal-141.example.com"
launch_configuration = "${aws_launch_configuration.master-us-test-1a-masters-minimal-141-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/minimal/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ output "vpc_id" {
value = "${aws_vpc.minimal-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_group" "master-us-test-1a-masters-minimal-example-com" {
name = "master-us-test-1a.masters.minimal.example.com"
launch_configuration = "${aws_launch_configuration.master-us-test-1a-masters-minimal-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/privatecalico/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ output "vpc_id" {
value = "${aws_vpc.privatecalico-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_attachment" "bastion-privatecalico-example-com" {
elb = "${aws_elb.bastion-privatecalico-example-com.id}"
autoscaling_group_name = "${aws_autoscaling_group.bastion-privatecalico-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/privatecanal/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ output "vpc_id" {
value = "${aws_vpc.privatecanal-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_attachment" "bastion-privatecanal-example-com" {
elb = "${aws_elb.bastion-privatecanal-example-com.id}"
autoscaling_group_name = "${aws_autoscaling_group.bastion-privatecanal-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/privatedns1/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ output "vpc_id" {
value = "${aws_vpc.privatedns1-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_attachment" "bastion-privatedns1-example-com" {
elb = "${aws_elb.bastion-privatedns1-example-com.id}"
autoscaling_group_name = "${aws_autoscaling_group.bastion-privatedns1-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/privatedns2/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ output "vpc_id" {
value = "vpc-123"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_attachment" "bastion-privatedns2-example-com" {
elb = "${aws_elb.bastion-privatedns2-example-com.id}"
autoscaling_group_name = "${aws_autoscaling_group.bastion-privatedns2-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/privateflannel/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ output "vpc_id" {
value = "${aws_vpc.privateflannel-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_attachment" "bastion-privateflannel-example-com" {
elb = "${aws_elb.bastion-privateflannel-example-com.id}"
autoscaling_group_name = "${aws_autoscaling_group.bastion-privateflannel-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/privatekopeio/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ output "vpc_id" {
value = "${aws_vpc.privatekopeio-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_attachment" "bastion-privatekopeio-example-com" {
elb = "${aws_elb.bastion-privatekopeio-example-com.id}"
autoscaling_group_name = "${aws_autoscaling_group.bastion-privatekopeio-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/privateweave/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ output "vpc_id" {
value = "${aws_vpc.privateweave-example-com.id}"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_attachment" "bastion-privateweave-example-com" {
elb = "${aws_elb.bastion-privateweave-example-com.id}"
autoscaling_group_name = "${aws_autoscaling_group.bastion-privateweave-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/shared_subnet/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ output "vpc_id" {
value = "vpc-12345678"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_group" "master-us-test-1a-masters-sharedsubnet-example-com" {
name = "master-us-test-1a.masters.sharedsubnet.example.com"
launch_configuration = "${aws_launch_configuration.master-us-test-1a-masters-sharedsubnet-example-com.id}"
Expand Down
4 changes: 4 additions & 0 deletions tests/integration/shared_vpc/kubernetes.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ output "vpc_id" {
value = "vpc-12345678"
}

provider "aws" {
region = "us-test-1"
}

resource "aws_autoscaling_group" "master-us-test-1a-masters-sharedvpc-example-com" {
name = "master-us-test-1a.masters.sharedvpc.example.com"
launch_configuration = "${aws_launch_configuration.master-us-test-1a-masters-sharedvpc-example-com.id}"
Expand Down
2 changes: 1 addition & 1 deletion upup/pkg/fi/cloudup/awsup/mock_aws_cloud.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ type MockCloud struct {
}

func (c *MockCloud) ProviderID() kops.CloudProviderID {
return "mock"
return kops.CloudProviderAWS
}

func (c *MockCloud) DNS() (dnsprovider.Interface, error) {
Expand Down

0 comments on commit e97efcc

Please sign in to comment.