29 lines
785 B
YAML
29 lines
785 B
YAML
apiVersion: networking.k8s.io/v1
|
|
kind: Ingress
|
|
metadata:
|
|
name: prometheus-ingress
|
|
namespace: monitoring
|
|
annotations:
|
|
# 인증 방법 설정: basic auth
|
|
nginx.ingress.kubernetes.io/auth-type: basic
|
|
# basic auth 사용자가 들어있는 secret 설정
|
|
nginx.ingress.kubernetes.io/auth-secret: basic-auth
|
|
# 인증 요청시 나오는 메세지 설정
|
|
nginx.ingress.kubernetes.io/auth-realm: 'Authentication Required - admin'
|
|
spec:
|
|
ingressClassName: nginx
|
|
rules:
|
|
- host: prometheus.nhngpuaas.com
|
|
http:
|
|
paths:
|
|
- backend:
|
|
service:
|
|
name: prometheus-server
|
|
port:
|
|
number: 80
|
|
path: /
|
|
pathType: Prefix
|
|
tls:
|
|
- hosts:
|
|
- prometheus.nhngpuaas.com
|
|
secretName: nhngpuaas-ssl |