<p>I have service configurd on my kuberntes cluster but when I try to curl ip:port I get connection refused
the following service configured :</p>
<pre><code>apiVersion: v1
kind: Service
metadata:
  name: frontend
  namespace: production
spec:
  type: NodePort
  selector:
    app: frontend
  ports:
   - name: control-center-web
     port: 8008
     protocol: TCP
     targetPort: 8008
</code></pre>
<p>$ kubectl describe svc frontend</p>
<pre><code> Name:                    frontend
    Namespace:                production
    Labels:                   &lt;none&gt;
    Annotations:              kubectl.kubernetes.io/last-applied-configuration:
                                {&quot;apiVersion&quot;:&quot;v1&quot;,&quot;kind&quot;:&quot;Service&quot;,&quot;metadata&quot;:{&quot;annotations&quot;:{},&quot;name&quot;:&quot;frontend&quot;,&quot;namespace&quot;:&quot;production&quot;},&quot;spec&quot;:{&quot;ports&quot;:[{&quot;name&quot;:...
    Selector:                 app=frontend
    Type:                     NodePort
    IP:                       &lt;ip&gt;
    Port:                     control-center-web  8008/TCP
    TargetPort:               8008/TCP
    NodePort:                 control-center-web  7851/TCP
    Endpoints:                &lt;none&gt;
    Session Affinity:         None
    External Traffic Policy:  Cluster
    Events:
      Type    Reason  Age   From                Message
      ----    ------  ----  ----                -------
      Normal  Type    14m   service-controller  LoadBalancer -&gt; NodePort
</code></pre>
<p>Why do I keep getting connection refuse for ip and port that I took from the svc?</p>

NoamiA
<p>The <code>Endpoints</code> in service has got <code>None</code> instead of IPs of the pods. This happens when the selector in service <code>app: frontend</code> does not match with the selector in pod spec,</p>
