2022-01-06 00:19:22 +08:00
|
|
|
{{ if and .Values.host .Values.path }}
|
|
|
|
kind: Ingress
|
|
|
|
apiVersion: networking.k8s.io/v1
|
|
|
|
metadata:
|
|
|
|
name: {{ .Release.Name }}
|
|
|
|
namespace: {{ .Values.nameSpace }}
|
2022-01-09 22:13:56 +08:00
|
|
|
labels:
|
|
|
|
app: {{ .Release.Name }}
|
|
|
|
app.kubernetes.io/version: v1
|
|
|
|
app.kubernetes.io/name: {{ .Release.Name }}
|
|
|
|
version: v1
|
|
|
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
2022-01-06 00:19:22 +08:00
|
|
|
annotations:
|
|
|
|
kubesphere.io/creator: drone
|
|
|
|
nginx.ingress.kubernetes.io/enable-cors: 'true'
|
|
|
|
nginx.ingress.kubernetes.io/rewrite-target: /$1
|
|
|
|
nginx.ingress.kubernetes.io/use-regex: 'true'
|
|
|
|
spec:
|
|
|
|
rules:
|
|
|
|
- host: {{ .Values.host }}
|
|
|
|
http:
|
|
|
|
paths:
|
|
|
|
- path: {{ .Values.path }}
|
|
|
|
pathType: ImplementationSpecific
|
|
|
|
backend:
|
|
|
|
service:
|
|
|
|
name: {{ .Release.Name }}
|
|
|
|
port:
|
|
|
|
number: 80
|
|
|
|
{{ end }}
|