Skip to content

Commit

Permalink
feat(helm): add support for spec.ingressClassName to Ingress template (
Browse files Browse the repository at this point in the history
  • Loading branch information
martinlindner authored May 9, 2022
1 parent 0fcc083 commit a06201a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions dev/helm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ The following table lists the configurable parameters of the Wiki.js chart and t
| `volumeMounts` | Volume mounts for Wiki.js container | `[]` |
| `volumes` | Volumes for Wiki.js Pod | `[]` |
| `ingress.enabled` | Enable ingress controller resource | `false` |
| `ingress.className` | Ingress class name | `""` |
| `ingress.annotations` | Ingress annotations | `{}` |
| `ingress.hosts` | List of ingress rules | `[{"host": "wiki.local", "paths": ["/"]}]` |
| `ingress.tls` | Ingress TLS configuration | `[]` |
Expand Down
3 changes: 3 additions & 0 deletions dev/helm/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ metadata:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if and .Values.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }}
ingressClassName: {{ .Values.ingress.className }}
{{- end }}
{{- if .Values.ingress.tls }}
tls:
{{- range .Values.ingress.tls }}
Expand Down
1 change: 1 addition & 0 deletions dev/helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ service:

ingress:
enabled: true
className: ""
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
Expand Down

0 comments on commit a06201a

Please sign in to comment.