Loading deploy/kubernetes/chart/files/fileServer/datasets.conf +10 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,12 @@ server { return 200; } # Basic metrics export, compatible with nginx exporter # https://github.com/nginx/nginx-prometheus-exporter location = /stub_status { stub_status; } # Create a location block for each dataset {{- range .Values.data.datasets }} location /thredds/fileServer/{{ .path }}/ { Loading @@ -26,6 +32,10 @@ server { proxy_pass https://{{ $s3.host }}:{{ $s3.port }}/{{ $s3.bucket }}/{{ trimAll "/" $s3.dataPath }}/; {{- else }} alias {{ trimSuffix "/" .location }}/; autoindex on; expires max; sendfile on; tcp_nopush on; try_files $uri =404; {{- end }} } Loading deploy/kubernetes/chart/templates/fileServer/configmap-nginx.yaml 0 → 100644 +10 −0 Original line number Diff line number Diff line {{- $fileServer := .Values.data.fileServer -}} {{- if (and .Values.data.enabled $fileServer.enabled (index $fileServer "nginx.conf")) -}} apiVersion: v1 kind: ConfigMap metadata: name: {{ include "esgf.component.fullname" (list . "fileServer") }}-nginx-conf labels: {{ include "esgf.component.labels" (list . "fileServer" $fileServer.labels) | nindent 4 }} data: nginx.conf: {{ tpl (index $fileServer "nginx.conf") . | quote }} {{- end -}} deploy/kubernetes/chart/templates/fileServer/configmap.yaml +1 −1 Original line number Diff line number Diff line Loading @@ -8,6 +8,6 @@ metadata: data: datasets.conf: {{ tpl (.Files.Get "files/fileServer/datasets.conf") . | quote }} {{ range $file, $content := $fileServer.extraNginxConf }} {{ $file }}: {{ tpl $content . | quote }} {{ $file }}: {{ tpl $content $ | quote }} {{- end }} {{- end -}} deploy/kubernetes/chart/templates/fileServer/deployment.yaml +15 −2 Original line number Diff line number Diff line Loading @@ -19,6 +19,9 @@ spec: # https://helm.sh/docs/howto/charts_tips_and_tricks/#automatically-roll-deployments annotations: checksum/configmap: {{ include (print $.Template.BasePath "/fileServer/configmap.yaml") . | sha256sum }} {{- if (index $fileServer "nginx.conf") }} checksum/configmap-nginx: {{ include (print $.Template.BasePath "/fileServer/configmap-nginx.yaml") . | sha256sum }} {{- end }} {{- if $accessLogSidecar.enabled }} # When the access log sidecar is enabled, roll the deployment if the logstash pipelines or certificates change checksum/logstash-pipelines: {{ include (print $.Template.BasePath "/logstash/pipelines.yaml") . | sha256sum }} Loading Loading @@ -82,7 +85,7 @@ spec: securityContext: {{ toYaml . | nindent 12 }} {{- end }} volumeMounts: - name: nginx-conf - name: nginx-extra mountPath: /etc/nginx/conf.d readOnly: true - name: static-content Loading @@ -99,6 +102,11 @@ spec: mountPath: /var/lib/nginx/tmp - name: nginx-run mountPath: /run/nginx {{- if (index $fileServer "nginx.conf") }} - name: nginx-conf mountPath: /etc/nginx/nginx.conf subPath: nginx.conf {{- end }} {{- include "esgf.data.volumeMounts" . | nindent 12 }} {{- with $fileServer.extraVolumeMounts }} {{- toYaml . | nindent 12 }} Loading Loading @@ -166,7 +174,7 @@ spec: tolerations: {{ toYaml . | nindent 8 }} {{- end }} volumes: - name: nginx-conf - name: nginx-extra configMap: name: {{ include "esgf.component.fullname" (list . "fileServer") }} - name: static-content Loading @@ -178,6 +186,11 @@ spec: emptyDir: {} - name: nginx-run emptyDir: {} {{- if (index $fileServer "nginx.conf") }} - name: nginx-conf configMap: name: {{ include "esgf.component.fullname" (list . "fileServer") }}-nginx {{- end }} # These volumes are only required if the access log sidecar is enabled {{- if $accessLogSidecar.enabled }} # Each pod gets a directory to hold the named pipes for the logs Loading deploy/kubernetes/chart/templates/fileServer/hpa.yaml +1 −1 Original line number Diff line number Diff line {{- $fileServer := .Values.data.fileServer -}} {{- if (and .Values.data.enabled $fileServer.enabled $fileServer.hpa) -}} apiVersion: autoscaling/v2beta2 apiVersion: autoscaling/v2 kind: HorizontalPodAutoscaler metadata: name: {{ include "esgf.component.fullname" (list . "fileServer") }} Loading Loading
deploy/kubernetes/chart/files/fileServer/datasets.conf +10 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,12 @@ server { return 200; } # Basic metrics export, compatible with nginx exporter # https://github.com/nginx/nginx-prometheus-exporter location = /stub_status { stub_status; } # Create a location block for each dataset {{- range .Values.data.datasets }} location /thredds/fileServer/{{ .path }}/ { Loading @@ -26,6 +32,10 @@ server { proxy_pass https://{{ $s3.host }}:{{ $s3.port }}/{{ $s3.bucket }}/{{ trimAll "/" $s3.dataPath }}/; {{- else }} alias {{ trimSuffix "/" .location }}/; autoindex on; expires max; sendfile on; tcp_nopush on; try_files $uri =404; {{- end }} } Loading
deploy/kubernetes/chart/templates/fileServer/configmap-nginx.yaml 0 → 100644 +10 −0 Original line number Diff line number Diff line {{- $fileServer := .Values.data.fileServer -}} {{- if (and .Values.data.enabled $fileServer.enabled (index $fileServer "nginx.conf")) -}} apiVersion: v1 kind: ConfigMap metadata: name: {{ include "esgf.component.fullname" (list . "fileServer") }}-nginx-conf labels: {{ include "esgf.component.labels" (list . "fileServer" $fileServer.labels) | nindent 4 }} data: nginx.conf: {{ tpl (index $fileServer "nginx.conf") . | quote }} {{- end -}}
deploy/kubernetes/chart/templates/fileServer/configmap.yaml +1 −1 Original line number Diff line number Diff line Loading @@ -8,6 +8,6 @@ metadata: data: datasets.conf: {{ tpl (.Files.Get "files/fileServer/datasets.conf") . | quote }} {{ range $file, $content := $fileServer.extraNginxConf }} {{ $file }}: {{ tpl $content . | quote }} {{ $file }}: {{ tpl $content $ | quote }} {{- end }} {{- end -}}
deploy/kubernetes/chart/templates/fileServer/deployment.yaml +15 −2 Original line number Diff line number Diff line Loading @@ -19,6 +19,9 @@ spec: # https://helm.sh/docs/howto/charts_tips_and_tricks/#automatically-roll-deployments annotations: checksum/configmap: {{ include (print $.Template.BasePath "/fileServer/configmap.yaml") . | sha256sum }} {{- if (index $fileServer "nginx.conf") }} checksum/configmap-nginx: {{ include (print $.Template.BasePath "/fileServer/configmap-nginx.yaml") . | sha256sum }} {{- end }} {{- if $accessLogSidecar.enabled }} # When the access log sidecar is enabled, roll the deployment if the logstash pipelines or certificates change checksum/logstash-pipelines: {{ include (print $.Template.BasePath "/logstash/pipelines.yaml") . | sha256sum }} Loading Loading @@ -82,7 +85,7 @@ spec: securityContext: {{ toYaml . | nindent 12 }} {{- end }} volumeMounts: - name: nginx-conf - name: nginx-extra mountPath: /etc/nginx/conf.d readOnly: true - name: static-content Loading @@ -99,6 +102,11 @@ spec: mountPath: /var/lib/nginx/tmp - name: nginx-run mountPath: /run/nginx {{- if (index $fileServer "nginx.conf") }} - name: nginx-conf mountPath: /etc/nginx/nginx.conf subPath: nginx.conf {{- end }} {{- include "esgf.data.volumeMounts" . | nindent 12 }} {{- with $fileServer.extraVolumeMounts }} {{- toYaml . | nindent 12 }} Loading Loading @@ -166,7 +174,7 @@ spec: tolerations: {{ toYaml . | nindent 8 }} {{- end }} volumes: - name: nginx-conf - name: nginx-extra configMap: name: {{ include "esgf.component.fullname" (list . "fileServer") }} - name: static-content Loading @@ -178,6 +186,11 @@ spec: emptyDir: {} - name: nginx-run emptyDir: {} {{- if (index $fileServer "nginx.conf") }} - name: nginx-conf configMap: name: {{ include "esgf.component.fullname" (list . "fileServer") }}-nginx {{- end }} # These volumes are only required if the access log sidecar is enabled {{- if $accessLogSidecar.enabled }} # Each pod gets a directory to hold the named pipes for the logs Loading
deploy/kubernetes/chart/templates/fileServer/hpa.yaml +1 −1 Original line number Diff line number Diff line {{- $fileServer := .Values.data.fileServer -}} {{- if (and .Values.data.enabled $fileServer.enabled $fileServer.hpa) -}} apiVersion: autoscaling/v2beta2 apiVersion: autoscaling/v2 kind: HorizontalPodAutoscaler metadata: name: {{ include "esgf.component.fullname" (list . "fileServer") }} Loading