<p>Sorry for that noobish question, but I'm having an issue reaching my pod and I have no idea why.. (I'm using Minikube locally)</p>
<p><strong>So I've created this basic pod:</strong></p>
<pre><code>apiVersion: v1
kind: Pod
metadata:
  name: myapp-pod
  labels:
    app: myapp
    type: front-end
spec:
  containers:
    - name: nginx-container
      image: nginx
      ports:
      - containerPort: 80
</code></pre>
<p><strong>And this basic service:</strong></p>
<pre><code>apiVersion: v1
kind: Service
metadata:
  name: service
  
spec:
  type: NodePort
  ports:
    - targetPort: 80
      port: 80
      nodePort: 30008
  selector:
    app: myapp
    type: front-end
</code></pre>
<p>However when I try reaching nginx through the browser I fail to do so..
I enter http://NodeIP:30008  .
However when I'm typing minikube service service --url I am able to access it..</p>
<p><strong>So basically I have 2 questions-</strong></p>
<p><strong>1-</strong> Why does my attempt enteting the nodeip and port fail? I 've seen that when I enter minikube ssh and try to curl here <strong>http://NodeIP:30008</strong> it works, so basically while I'm using Minikube I won't be able to browse to my apps? only curl through the minikube ssh or the below command.?</p>
<p><strong>2-</strong> Why does the minikube service --url command works? what's the difference?</p>
<p>Thanks a lot!</p>

Asaf
<p>Use the external IP address (LoadBalancer Ingress) to access to your application:</p>
<p>curl http://&lt;external-ip&gt;:&lt;port&gt;</p>
<p>where  is the external IP address (LoadBalancer Ingress) of your Service, and  is the value of Port in your Service description. <em><strong>If you are using minikube, typing minikube service my-service will automatically open your application in a browser.</strong></em></p>
<p>You can find more details <a href="https://kubernetes.io/docs/tutorials/stateless-application/expose-external-ip-address/" rel="nofollow noreferrer">here</a></p>
