diff --git a/.gitignore b/.gitignore index 0094da2..6c8b147 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,5 @@ dispatcher *.gpg conf/conf_env.yml values-*.yaml +conf/* +!conf/*example* \ No newline at end of file diff --git a/templates/configmap.yaml b/templates/configmap.yaml index c901bc8..5c678a3 100644 --- a/templates/configmap.yaml +++ b/templates/configmap.yaml @@ -7,29 +7,43 @@ data: osa_data_server_conf.yml: | instruments: isgri: - dispatcher_mnt_point: /data - data_server_cache: reduced/ddcache - dummy_cache: /data/dummy_prods - data_server_url: http://oda-dda-interface:8000 + dispatcher_mnt_point: /data + data_server_cache: reduced/ddcache + dummy_cache: /data/dummy_prods + data_server_url: {{ .Values.isgri_data_server_url | default "http://oda-dda-interface:8000" }} jemx: - dispatcher_mnt_point: /data - data_server_cache: reduced/ddcache - dummy_cache: /data/dummy_prods - data_server_url: http://oda-dda-interface:8000 + dispatcher_mnt_point: /data + data_server_cache: reduced/ddcache + dummy_cache: /data/dummy_prods + data_server_url: {{ .Values.jemx_data_server_url | default "http://oda-dda-interface:8000" }} magic_data_server_conf.yml: | instruments: magic: - data_server_url: http://oda-magic:8000 + data_server_url: {{ .Values.magic_data_server_url | default "http://oda-magic:8000" }} polar_data_server_conf.yml: | instruments: polar: - dispatcher_mnt_point: - data_server_cache: - dummy_cache: dummy_prods - data_server_url: polar-worker - data_server_port: 8893 + dispatcher_mnt_point: + data_server_cache: + dummy_cache: dummy_prods + data_server_url: {{ .Values.polar_data_server_url | default "polar-worker" }} + data_server_port: {{ .Values.polar_data_server_port | default 8893 }} + + antares_data_server_conf.yml: | + instruments: + antares: + data_server_url: {{ .Values.antares_data_server_url | default "http://oda-antares:8000" }} + dummy_cache: dummy_prods + + spiacs_data_server_conf: | + instruments: + spi_acs: + dispatcher_mnt_point: + data_server_cache: + dummy_cache: dummy_prods + data_server_url: {{ .Values.spiacs_data_server_url | default "https://www.astro.unige.ch/cdci/astrooda/dispatch-data/gw/integralhk/api/v1.0/genlc/ACS/{t0_isot}/{dt_s}" }} diff --git a/templates/deployment.yaml b/templates/deployment.yaml index ccfc31a..d29bea6 100644 --- a/templates/deployment.yaml +++ b/templates/deployment.yaml @@ -53,18 +53,20 @@ spec: hostPath: path: {{ .Values.oda.ddcache }} {{ else }} - - name: scratch - persistentVolumeClaim: - claimName: dda-interface-scratch - name: dispatcher-scratch-root persistentVolumeClaim: claimName: dispatcher-scratch-root - name: filelogdir persistentVolumeClaim: - claimName: dda-filelogdir + claimName: dispatcher-filelogdir + {{- if .Values.mount_dda }} + - name: scratch + persistentVolumeClaim: + claimName: dda-interface-scratch - name: data-reduced-ddcache persistentVolumeClaim: claimName: data-reduced-ddcache + {{- end }} #- name: isdc-arc-rev3 #- name: isdc-pvphase-nrt-ops {{ end }} @@ -122,31 +124,27 @@ spec: value: "no" {{- end }} volumeMounts: - - mountPath: /scratch - name: scratch - mountPath: /var/log/containers name: filelogdir - - mountPath: /data/reduced/ddcache - name: data-reduced-ddcache - mountPath: /data/dispatcher_scratch name: dispatcher-scratch-root + {{- if .Values.mount_dda }} + - mountPath: /data/reduced/ddcache + name: data-reduced-ddcache + - mountPath: /scratch + name: scratch + {{- end }} - mountPath: /dispatcher/conf/conf_env.yml name: dispatcher-conf-secret subPath: conf_env.yml readOnly: true + {{- range $plugin := list "osa" "magic" "polar" "antares" "spiacs" }} - name: dispatcher-config-volume - mountPath: /dispatcher/conf/conf.d/osa_data_server_conf.yml - subPath: osa_data_server_conf.yml - readOnly: true - - name: dispatcher-config-volume - mountPath: /dispatcher/conf/conf.d/polar_data_server_conf.yml - subPath: polar_data_server_conf.yml - readOnly: true - - name: dispatcher-config-volume - mountPath: /dispatcher/conf/conf.d/magic_data_server_conf.yml - subPath: magic_data_server_conf.yml + mountPath: /dispatcher/conf/conf.d/{{$plugin}}_data_server_conf.yml + subPath: {{$plugin}}_data_server_conf.yml readOnly: true + {{- end }} - name: celery securityContext: diff --git a/values.yaml b/values.yaml index a46a488..a2ee6ab 100644 --- a/values.yaml +++ b/values.yaml @@ -101,6 +101,8 @@ tolerations: [] affinity: {} oda: - use_hostpath: true ddaQueue: queue-osa11 ddcache: "/net/cdcicn02/scratch/shared/savchenk/data/reduced/ddcache" +use_hostpath: true +mount_dda: true # mount dda-related volumes into dispatcher + # MUST be false if installing dispatcher without dda backend \ No newline at end of file