Merge "Fix elasticsearch repository configuration entry"

This commit is contained in:
Zuul 2018-01-06 23:30:18 +00:00 committed by Gerrit Code Review
commit f41cec95a3
6 changed files with 12 additions and 5 deletions

View File

@ -16,6 +16,10 @@ limitations under the License.
{{- if .Values.manifests.configmap_etc }} {{- if .Values.manifests.configmap_etc }}
{{- $envAll := . }} {{- $envAll := . }}
{{- if and (.Values.conf.elasticsearch.repository.enabled) (empty .Values.conf.elasticsearch.config.path.repo) -}}
{{- set .Values.conf.elasticsearch.config.path "repo" .Values.conf.elasticsearch.repository.location -}}
{{- end -}}
--- ---
apiVersion: v1 apiVersion: v1
kind: ConfigMap kind: ConfigMap

View File

@ -165,7 +165,7 @@ spec:
mountPath: {{ .Values.conf.elasticsearch.config.path.data }} mountPath: {{ .Values.conf.elasticsearch.config.path.data }}
{{ if .Values.storage.filesystem_repository.enabled }} {{ if .Values.storage.filesystem_repository.enabled }}
- name: snapshots - name: snapshots
mountPath: {{ .Values.conf.elasticsearch.config.path.repo }} mountPath: {{ .Values.conf.elasticsearch.repository.location }}
{{ end }} {{ end }}
{{ if $mounts_elasticsearch.volumeMounts }}{{ toYaml $mounts_elasticsearch.volumeMounts | indent 12 }}{{ end }} {{ if $mounts_elasticsearch.volumeMounts }}{{ toYaml $mounts_elasticsearch.volumeMounts | indent 12 }}{{ end }}
volumes: volumes:

View File

@ -124,7 +124,7 @@ spec:
mountPath: {{ .Values.conf.elasticsearch.config.path.data }} mountPath: {{ .Values.conf.elasticsearch.config.path.data }}
{{ if .Values.storage.filesystem_repository.enabled }} {{ if .Values.storage.filesystem_repository.enabled }}
- name: snapshots - name: snapshots
mountPath: {{ .Values.conf.elasticsearch.config.path.repo }} mountPath: {{ .Values.conf.elasticsearch.repository.location }}
{{ end }} {{ end }}
{{ if $mounts_elasticsearch.volumeMounts }}{{ toYaml $mounts_elasticsearch.volumeMounts | indent 12 }}{{ end }} {{ if $mounts_elasticsearch.volumeMounts }}{{ toYaml $mounts_elasticsearch.volumeMounts | indent 12 }}{{ end }}
volumes: volumes:

View File

@ -15,6 +15,7 @@ limitations under the License.
*/}} */}}
{{- if .Values.manifests.job_snapshot_repository }} {{- if .Values.manifests.job_snapshot_repository }}
{{- if .Values.conf.elasticsearch.repository.enabled }}
{{- $envAll := . }} {{- $envAll := . }}
{{- $_ := set .Values "pod_dependency" .Values.dependencies.snapshot_repository -}} {{- $_ := set .Values "pod_dependency" .Values.dependencies.snapshot_repository -}}
@ -49,7 +50,7 @@ spec:
- name: REPO_TYPE - name: REPO_TYPE
value: {{ .Values.conf.elasticsearch.repository.type | quote }} value: {{ .Values.conf.elasticsearch.repository.type | quote }}
- name: REPO_LOCATION - name: REPO_LOCATION
value: {{ .Values.conf.elasticsearch.config.path.repo | quote }} value: {{ .Values.conf.elasticsearch.repository.location | quote }}
command: command:
- /tmp/register-repository.sh - /tmp/register-repository.sh
volumeMounts: volumeMounts:
@ -63,3 +64,4 @@ spec:
name: elasticsearch-bin name: elasticsearch-bin
defaultMode: 0555 defaultMode: 0555
{{- end }} {{- end }}
{{- end }}

View File

@ -154,7 +154,7 @@ spec:
readOnly: true readOnly: true
{{ if .Values.storage.filesystem_repository.enabled }} {{ if .Values.storage.filesystem_repository.enabled }}
- name: snapshots - name: snapshots
mountPath: {{ .Values.conf.elasticsearch.config.path.repo }} mountPath: {{ .Values.conf.elasticsearch.repository.location }}
{{ end }} {{ end }}
- name: storage - name: storage
mountPath: {{ .Values.conf.elasticsearch.config.path.data }} mountPath: {{ .Values.conf.elasticsearch.config.path.data }}

View File

@ -246,9 +246,10 @@ conf:
path: path:
data: /usr/share/elasticsearch/data data: /usr/share/elasticsearch/data
logs: /usr/share/elasticsearch/logs logs: /usr/share/elasticsearch/logs
repo: /var/lib/openstack-helm/elasticsearch
repository: repository:
enabled: true
name: default_repo name: default_repo
location: /var/lib/openstack-helm/elasticsearch
type: fs type: fs
env: env:
java_opts: "-Xms256m -Xmx256m" java_opts: "-Xms256m -Xmx256m"