<p>I'm trying to deploy apps with Kubernetes and minikube. But I have a strange issue: i can access my app with curl in terminal but not from browser.
I'm using &quot;minikube tunnel&quot; command for external ip.</p>
<p><a href="https://i.stack.imgur.com/rPtqC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/rPtqC.png" alt="enter image description here" /></a></p>
<p><a href="https://i.stack.imgur.com/ZvI8W.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ZvI8W.png" alt="enter image description here" /></a></p>
<p>This is my deployment and service files</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint-override"><code>apiVersion: apps/v1
kind: Deployment
metadata:
  name: nodeapp-deployment
  labels:
    app: nodeapp
spec:
  replicas: 1
  selector:
    matchLabels:
      app: nodeapp
  template:
    metadata:
      labels:
        app: nodeapp
    spec:
      containers:
      - name: nodeserver
        image:  tanyadovzhenko/chi-questionnaire-back
        env:
          - name: PORT
            value: "4000"
          - name: JWT_ACCESS_KEY
            value: "111"
          - name: JWT_REFRESH_KEY
            value: "111"
          - name: HASH_PASSWORD_ALGORITM
            value: "sha256"
        ports:
        - containerPort: 4000</code></pre>
</div>
</div>
</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint-override"><code>apiVersion: v1
kind: Service
metadata:
  name: nodeapp-service
spec:
  selector:
    app: nodeapp
  type: LoadBalancer
  ports:
  - protocol: TCP
    port: 4000
    targetPort: 4000</code></pre>
</div>
</div>
</p>

kisa_2001
<p>This is a <a href="https://minikube.sigs.k8s.io/docs/drivers/docker/#known-issues" rel="nofollow noreferrer">known issue</a> for minikube and ingress is only limited to Linux. Using minikube service with a tunnel the network is limited if using the Docker driver on Darwin, Windows, or WSL, and the Node IP is not reachable directly.  Running minikube on Linux with the Docker driver will result in no tunnel being created. Follow this <a href="https://minikube.sigs.k8s.io/docs/handbook/accessing/#:%7E:text=minikube%20tunnel%20runs%20as%20a,on%20the%20host%20operating%20system" rel="nofollow noreferrer">tunneling</a> into Minikube for accessing it on the browser.  Alternatively you can run this command <code>minikube service &lt;SERVICE_NAME&gt; --url</code> which will give you a direct URL to access the application and access the URL in the web browser.</p>
<p>As per this <a href="https://stackoverflow.com/a/71749078/19230181">Thread</a> by the community member Aniki you can also resolve it by changing minikube base driver to hyperv from docker.</p>
