Skip to content
Snippets Groups Projects

swh: add storage service

Closed Guillaume Samson requested to merge 4811_swh_storage into staging
4 unresolved threads
Files
11
+ 29
0
 
{{ if .Values.storage.enabled -}}
 
---
 
apiVersion: v1
 
kind: ConfigMap
 
metadata:
 
namespace: {{ .Values.namespace }}
 
name: storage-configuration-template
 
data:
 
config.yml.template: |
 
storage:
 
cls: {{ .Values.storage.storageClass }}
 
{{- if eq .Values.storage.storageClass "cassandra" }}
 
hosts:
    • We'll have to specialize this part for postgresql or cassandra version, but it can be done later when we'll have the need

      • Indeed, to explicit, the hosts, consistency, ... key entries are cassandra backend specificities. For postgresql, for example, we'll have a db key (or something). As for cls remote, we have a url key.

        But yes, later, when the need arise.

        Edited by Antoine R. Dumont
      • Please register or sign in to reply
Please register or sign in to reply
 
{{- range $seed := .Values.storage.cassandra.seeds }}
 
- {{ $seed }}
 
{{- end }}
 
keyspace: {{ .Values.storage.cassandra.keySpace }}
 
consistency_level: {{ .Values.storage.cassandra.consistencyLevel }}
 
{{- else if eq .Values.storage.storageClass "postgresql" }}
 
db: host={{ .Values.storage.postgresql.host }} port={{ .Values.storage.postgresql.port | default "5432" }} user={{ .Values.storage.postgresql.user | default "guest" }} dbname={{ .Values.storage.postgresql.db | default "swh" }} password=${POSTGRESQL_PASSWORD}
 
{{- end }}
 
{{- if .Values.storage.specific_options -}}
 
{{- range $option, $value := .Values.storage.specific_options }}
 
{{ $option }}: {{ $value }}
 
{{- end }}
 
{{- end }}
 
objstorage:
 
{{- toYaml .Values.storage.objstorage | nindent 8 }}
 
{{- end -}}
Loading