Skip to content

Commit

Permalink
Commit triggered by a change on the main branch of helm-charts-dev
Browse files Browse the repository at this point in the history
  • Loading branch information
kalxas committed Feb 13, 2023
1 parent dd6153a commit 3140249
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 1 deletion.
2 changes: 1 addition & 1 deletion charts/rm-resource-catalogue/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 1.2.0
version: 1.2.2

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down
3 changes: 3 additions & 0 deletions charts/rm-resource-catalogue/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ The configuration parameters in this section control the resource catalogue conf
| db.volume_name | Volume name that stores the database data | `resource-catalogue-db-data` |
| db.volume_path | Volume path for the database data | `/var/lib/postgresql/data/pgdata` |
| db.volume_size | Volume size to store the database data | `500Mi` |
| ingress.enabled | Set true to enable the ingress controler, false to disable | `true` |
| ingress.subpath_enabled | Set true to enable path based configuration of the ingress controler, false to disable | `false` |
| ingress.subpath | Subpath of the resource catalogue to be set to the ingress rules/rewrites. The pycsw.config.server.url value should be set accordingly | `/resource-catalogue` |
| ingress.name | Name of the Kubernetes ingress for the catalogue | `resource-catalogue` |
| ingress.class | Class of the Kubernetes ingress | `nginx` |
| ingress.host | Hostname to be used by the Kubernetes ingress controler | `resource-catalogue.demo.eoepca.org` |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@ metadata:
{{- with .Values.ingress.annotations }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- if .Values.ingress.subpath_enabled }}
{{- with .Values.ingress.subpath_annotations }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- end }}
spec:
{{- if and .Values.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }}
ingressClassName: {{ .Values.ingress.class }}
Expand All @@ -25,6 +30,36 @@ spec:
- host: {{ .Values.ingress.host }}
http:
paths:
{{- if .Values.ingress.subpath_enabled }}
- path: {{ .Values.ingress.subpath }}/(.*)
{{- if semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion }}
pathType: Prefix
{{- end }}
backend:
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
service:
name: {{ .Values.pycsw.service_name }}
port:
number: {{ .Values.pycsw.service_port }}
{{- else }}
serviceName: {{ .Values.pycsw.service_name }}
servicePort: {{ .Values.pycsw.service_port }}
{{- end }}
- path: {{ .Values.ingress.subpath }}$
{{- if semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion }}
pathType: Exact
{{- end }}
backend:
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
service:
name: {{ .Values.pycsw.service_name }}
port:
number: {{ .Values.pycsw.service_port }}
{{- else }}
serviceName: {{ .Values.pycsw.service_name }}
servicePort: {{ .Values.pycsw.service_port }}
{{- end }}
{{- else }}
- path:
{{- if semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion }}
pathType: "ImplementationSpecific"
Expand All @@ -39,6 +74,7 @@ spec:
serviceName: {{ .Values.pycsw.service_name }}
servicePort: {{ .Values.pycsw.service_port }}
{{- end }}
{{- end }}
tls:
- hosts:
- {{ .Values.ingress.tls_host }}
Expand Down
6 changes: 6 additions & 0 deletions charts/rm-resource-catalogue/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,16 @@ ingress:
host: resource-catalogue.demo.eoepca.org
tls_host: resource-catalogue.demo.eoepca.org
tls_secret_name: resource-catalogue-tls
subpath_enabled: false
subpath: "/resource-catalogue"
default_annotations:
kubernetes.io/ingress.class: "{{ .Values.ingress.class }}"
nginx.ingress.kubernetes.io/enable-cors: "true"
nginx.ingress.kubernetes.io/proxy-read-timeout: "600"
subpath_annotations:
nginx.ingress.kubernetes.io/rewrite-target: /$1
nginx.ingress.kubernetes.io/configuration-snippet: |
rewrite ^({{ .Values.ingress.subpath }})$ $1/ redirect;
annotations:
cert-manager.io/cluster-issuer: letsencrypt

Expand Down

0 comments on commit 3140249

Please sign in to comment.