diff --git a/opendata-ogc-features/Chart.yaml b/opendata-ogc-features/Chart.yaml index cb2b091..4832c64 100644 --- a/opendata-ogc-features/Chart.yaml +++ b/opendata-ogc-features/Chart.yaml @@ -4,6 +4,6 @@ description: Helm chart for data-api (opendata-ogc-features) type: application -version: 0.0.3 +version: 0.0.4 appVersion: "1.0.0" diff --git a/opendata-ogc-features/templates/opendata-ogc-features-config-cm.yaml b/opendata-ogc-features/templates/opendata-ogc-features-config-cm.yaml new file mode 100644 index 0000000..611db6b --- /dev/null +++ b/opendata-ogc-features/templates/opendata-ogc-features-config-cm.yaml @@ -0,0 +1,11 @@ +{{- if .Values.ogcFeatConfig }} +apiVersion: v1 +kind: ConfigMap +metadata: + labels: + app.kubernetes.io/component: opendata-ogc-features + name: ogc-feat-config-cm +data: + application.yaml: | + {{- .Values.ogcFeatConfig | nindent 4 }} +{{- end }} \ No newline at end of file diff --git a/opendata-ogc-features/templates/opendata-ogc-features-depl.yaml b/opendata-ogc-features/templates/opendata-ogc-features-depl.yaml index 44c968a..a108a04 100644 --- a/opendata-ogc-features/templates/opendata-ogc-features-depl.yaml +++ b/opendata-ogc-features/templates/opendata-ogc-features-depl.yaml @@ -3,7 +3,7 @@ kind: Deployment metadata: creationTimestamp: null labels: - app.mel.fr/name: opendata-ogc-features + app.kubernetes.io/name: opendata-ogc-features name: opendata-ogc-features-depl spec: replicas: {{ .Values.replicaCount }} @@ -27,6 +27,10 @@ spec: {{- with .Values.environment }} {{- . | toYaml | nindent 8 }} {{- end }} + {{- if .Values.ogcFeatConfig }} + - name: JAVA_TOOL_OPTIONS + value: "-Ddataapi.configdir=/etc" + {{- end }} livenessProbe: httpGet: path: {{ .Values.livenessProbeHttpUrl }} @@ -40,7 +44,16 @@ spec: port: 8081 initialDelaySeconds: 60 periodSeconds: 10 + {{- if .Values.ogcFeatConfig }} + volumeMounts: + - mountPath: /etc/data-api/ + name: ogc-feat-config + volumes: + - name: ogc-feat-config + configMap: + name: ogc-feat-config-cm + {{- end }} {{- if .Values.tolerations }} tolerations: {{- .Values.tolerations | toYaml | nindent 6 }} - {{- end }} \ No newline at end of file + {{- end }} diff --git a/opendata-ogc-features/values.yaml b/opendata-ogc-features/values.yaml index 41005a2..4413ad7 100644 --- a/opendata-ogc-features/values.yaml +++ b/opendata-ogc-features/values.yaml @@ -44,3 +44,4 @@ environment: key: password name: georchestra-database-geodata-secret tolerations: [] +ogcFeatConfig: {} \ No newline at end of file