Why can Kubernetes not route a service on public ELB on AWS?

5/12/2016

I've been trying to follow the example (guestbook) to reproduce another application which has to be available on a public interface.

This is my Kubernetes configuration (YAML):

apiVersion: v1
kind: Service
metadata:
  name: my-app-server
  labels:
    app: my-app-server
    tier: backend
spec:
  type: LoadBalancer
  ports:
  - port: 80
    targetPort: 3000
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  name: my-app-server
spec:
  replicas: 3
  template:
    metadata:
      labels:
        app: my-app-server
        tier: backend
    spec:
      containers:
      - name: ppm-server
        image: docker/container:tag
        imagePullPolicy: Always
        resources:
          requests:
            cpu: 100m
            memory: 100Mi
        env:
        - name: GET_HOSTS_FROM
          value: dns
        ports:
        - containerPort: 3000
      imagePullSecrets:
        - name: myregistrykey

Not sure why this is not working.

The guestbook all-in-one example seems to work just fine though.

I tried using the exact same configuration file while just changing the variables in the configuration.

-- chbh
amazon-web-services
kubernetes

0 Answers