<p>i want to access to the server with this route but not worked . <code>https://ticketing.dev/api/user/currentuser</code></p>
<p>i craete in the root folder <code>skaffold.yaml</code>:</p>
<pre><code>apiVersion: skaffold/v2beta11
kind: Config
deploy:
  kubectl:
    manifests:
      - ./infra/k8s/*
build:
  local:
    push: false
  artifacts:
    - image: kia9372/auth
      context: auth
      docker:
        dockerfile: Dockerfile
      sync:
        manual:
          - src: 'src/**/*.ts'
            dest: .
</code></pre>
<p>and i crate a folder by name <code>infra</code> and in that i create a folder by name <code>k8s</code> . in this folder i create two file :</p>
<p><strong>A :</strong> <code>auth-depl.yaml</code></p>
<pre><code>apiVersion: apps/v1
kind: Deployment
metadata:
  name: auth-depl
spec:
  replicas: 1
  selector:
    matchLabels:
      app: auth
  template:
    metadata:
      labels:
        app: auth
    spec:
      containers:
        - name: auth
          image: kia9372/auth
---
apiVersion: v1
kind: Service
metadata:
  name: auth-srv
spec:
  selector:
    app: auth
  ports:
    - name: auth
      protocol: TCP
      port: 4000
      targetPort: 4000
</code></pre>
<p><strong>B :</strong> <code>ingress-srv.yaml</code></p>
<pre><code>apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: minimal-ingress
  annotations:
    nginx.ingress.kubernetes.io/rewrite-target: /
spec:
  rules:
  - host: ticketing.dev
  - http:
      paths:
      - path: /api/user/?(.*)
        backend:
          service:
            name: auth-srv
            port:
              number: 4000
</code></pre>
<p>and into the <code>/etc/hosts</code> i writeing this :</p>
<pre><code> # The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters


127.0.0.1   localhost
127.0.1.1   mr-programmer
127.0.1.1   ticketing.dev
</code></pre>
<p>but now i have a problem . when i want to go in this route <code>https://ticketing.dev/api/user/currentuser</code> it not show my any things . i test the server seprate the kubernetes by this <code>https://localhost:4000/api/user/currentuser</code> and it works .</p>
<p><strong>whats the prblem ? how can i solve this problem ?</strong></p>

Mr-Programer
<p><code>Solution</code> :</p>
<ol>
<li>Go to your terminal</li>
<li>Enter <code>minikube ip</code> - you will get minikube ip ( examle : 172.17.0.2)</li>
<li><code>Edit /etc/hosts</code> :</li>
</ol>
<p>change <code>127.0.1.1   ticketing.dev</code> to
<code>172.17.0.2 (minikube ip)   ticketing.dev</code></p>
<p>You can not write here local ip address(127.0.1.1), you should write here minikube ip address(172.17.0.2), because you are using minikube.</p>
