<p>I have simple ingress for virtual hosting:</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: ingress-access
spec:
  rules:
  - host: service1.domain.com
    http: 
      paths:
      - backend:     
          serviceName: service1
          servicePort: 80
  - host: service2.domain.com
    http:
      paths:
      - backend:
          serviceName: service2
          servicePort: 80
</code></pre>

<p>Services service1 and servcie2 have definitions like:</p>

<pre><code>apiVersion: v1
kind: Service
metadata:
  name: service1
  labels:
    chart: "chart"
spec:
  type: ClusterIP # LoadBalancer
  ports:
  - port: 80
    targetPort: 80
    protocol: TCP
    name: web
  selector:
    app: service1
</code></pre>

<p>If I deploy services with type <code>ClusterIP</code> they don't work, ingress responds with error: </p>

<pre><code>Error: Server Error
The server encountered a temporary error and could not complete your request.
Please try again in 30 seconds.
</code></pre>

<p>Then I change type of one of the services to <code>LoadBalancer</code>, it gets external IP and I can access it using this external IP, and also I can access it though ingress (using host name <code>service1.domain.com</code>)</p>

<p>If I try to access service2 (service2.domain.com - which still has type <code>ClusterIP</code>) ingress responds with:</p>

<pre><code>default backend - 404
</code></pre>

<p>If I change servcice2 type to <code>LoadBalancer</code> it starts to work through ingress.</p>

<p>I think that ingress should work with <code>ClusterIP</code> services, because LoadBalancer service type assigns external IP, which is not needed at all, and if I get it correctly gcloud ingress resource by default should use its own load loadbalancer.</p>

<p>So what is wrong with the setup?</p>

<p><a href="https://github.com/kubernetes/ingress-gce/blob/master/docs/faq/gce.md" rel="nofollow noreferrer">https://github.com/kubernetes/ingress-gce/blob/master/docs/faq/gce.md</a></p>
<p>It seems that the correct answer is that Ingress requires NodePort to work with, so services should have <code>NodePort</code> type for this case.</p>
