Authentification before connecting in Kibana with Kubernetes and Ingress

#1

Hi,

I had a kubernetes cluster with Kibana and Elasticsearch. It works well. Now I want to add an authentification with Ingress (user/password). I want results like this link : https://blog.bigbinary.com/2018/08/14/using-kubernetes-ingress-authentication.html
The url server was not found when I want to connect with my Ingress URL.
The Ingress controller has 0 pods.

I try to modify the env variable server basename in kibana.yaml but no success.
Here my kibana.yaml :
apiVersion: apps/v1beta1
kind: Deployment
metadata:
name: kibana
labels:
component: kibana
spec:
replicas: 1
selector:
matchLabels:
component: kibana
template:
metadata:
labels:
component: kibana
spec:
containers:
- name: kibana
image: docker.elastic.co/kibana/kibana-oss:6.3.2
env:
- name: CLUSTER_NAME
value: myesdb
# name: SERVER_BASEPATH
#value: /kibana.internal.carlosedp.com
#value: /kibana
#value: /api/v1/namespaces/default/services/kibana:http/proxy
resources:
limits:
cpu: 1000m
requests:
cpu: 100m
ports:
- containerPort: 5601
name: http
readinessProbe:
httpGet:
path: /api/status
port: http
initialDelaySeconds: 20
timeoutSeconds: 5
volumeMounts:
- name: config
mountPath: /usr/share/kibana/config
readOnly: true
volumes:
- name: config
configMap:
name: kibana-config

Here my Ingress.yaml
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: ingress-with-auth
annotations:
# type of authentication
nginx.ingress.kubernetes.io/auth-type: basic
# name of the secret that contains the user/password definitions
nginx.ingress.kubernetes.io/auth-secret: mypasswd
# message to display with an appropriate context why the authentication is required
nginx.ingress.kubernetes.io/auth-realm: ‘Authentication Required - foo’
spec:
rules:
host: (linkhost)
http:
paths:
path: /
backend:
serviceName: kibana-service
servicePort: 5601

Thank you