Reputation: 771
When running skaffold dev command, I get this error:
- for: "STDIN": admission webhook "validate.nginx.ingress.kubernetes.io" denied the request: host "ticketing.dev" and path "/api/users/?(.*)" is already defined in ingress default/ingress-service
time="2021-06-20T19:55:11+03:00" level=warning msg="Skipping deploy due to error: kubectl apply: exit status 1"
when I change the path "/api/users/?(.)" to something like "/api/usersssss/?(.)", the error dissapears
restarting my machine doesn't help
any que?
ingress-srv.yaml:
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: ingress-srv
annotations:
kubernetes.io/ingress.class: nginx
nginx.ingress.kubernetes.io/use-regex: 'true'
spec:
rules:
- host: ticketing.dev
http:
paths:
- path: /api/users/?(.*)
pathType: Prefix
backend:
service:
name: auth-srv
port:
number: 3000
skaffold.yaml:
apiVersion: skaffold/v2beta17
kind: Config
metadata:
name: tickets
build:
artifacts:
- image: natankamusher/auth
context: auth
docker:
dockerfile: Dockerfile
deploy:
kubectl:
manifests:
- infra/k8s/auth-depl.yaml
- infra/k8s/ingress-srv.yaml
Upvotes: 0
Views: 2747
Reputation: 331
run the below command to
kubectl delete Ingress ingress-srv
ingress-srv is the name of the service
Upvotes: 1