[solved!] AWS load balancer not being created. help?

We’ve got a Rancher-Server running at AWS, we’ve created a k8s env and i’ve created a demo deployment and service running nginx.

Service is type “loadbalancer”

(we’re running in a VPC in a private subnet)

I see the deployment and service all successfully created - but the loadbalancer ingress is a private IP.

“status”: {
“loadBalancer”: {
“ingress”: [
{
“ip”: “PRIVATE IP”
}

And I do not see any LB created at AWS.

So to sum up; Deployment and service created successfully through k8s.
Loadbalancer not being created at AWS.

Our r-hosts have elb-full-access roles attached (and our r-server does as well, since I have been trying to troubleshoot this)

Any help?
I’m under the impression that by declaring “type: loadbalancer” for my service, there should be a LB created at AWS. Is that correct?

AAnnnd it just worked.
OK. unsure why it wasn’t working previously. But we did tear down our Cloud formation stack with rancher server and bring it back. So, something must have been missing in the previous install.

We figured out that we needed to do two things:

  1. Change the default Kubernetes template configuration to use the “aws” cloud provider.

  2. Grant various policy permissions to every rancher host we add to the cluster, which we do with a Role/InstanceProfile. The particular policy needed is:

    {“Version”:“2012-10-17”,“Statement”:[{“Action”:“elasticloadbalancing:",“Resource”:"”,“Effect”:“Allow”}]}

I posted details in How To: Deploy Rancher/Kubernetes in Amazon VPC private subnet