Skip to content

Commit

Permalink
Merge pull request #40 from thesse1/add-elasticsearch-resources
Browse files Browse the repository at this point in the history
Add configuration for Elasticsearch resources and storage size
  • Loading branch information
MarcFriedhoff authored Feb 13, 2024
2 parents 1380a3b + 566e097 commit 750f466
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
14 changes: 14 additions & 0 deletions apigateway/helm/templates/elasticsearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,16 @@ spec:
# use default node set
- name: default
count: {{ .Values.elasticsearch.defaultNodeSet.count }}
volumeClaimTemplates:
- metadata:
name: elasticsearch-data # Do not change this name unless you set up a volume mount for the data path.
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: {{ default "1Gi" .Values.elasticsearch.storage }}
storageClassName: {{ default "default" .Values.elasticsearch.storageClassName }}
config:
{{- if not .Values.elasticsearch.defaultNodeSet.memoryMapping }}
node.store.allow_mmap: false
Expand All @@ -86,6 +96,10 @@ spec:
spec:
imagePullSecrets:
{{- toYaml .Values.imagePullSecrets | nindent 12 }}
containers:
- name: elasticsearch
resources:
{{- toYaml .Values.elasticsearch.resources | nindent 14 }}
initContainers:
{{- if and .Values.elasticsearch.defaultNodeSet.setMaxMapCount .Values.elasticsearch.defaultNodeSet.memoryMapping }}
- name: sysctl
Expand Down
14 changes: 14 additions & 0 deletions apigateway/helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,20 @@ elasticsearch:
# Make sure that the image corresponds to the version field.
image:

# -- Resource Settings for Elasticsearch
# Example:
#
# limits:
# cpu: 100m
# memory: 128Mi
# requests:
# cpu: 100m
# memory: 128Mi
resources: {}

storage: ""
storageClassName: ""

# -- The secret name that holds the sag es user for API Gateway.
secretName: ""

Expand Down

0 comments on commit 750f466

Please sign in to comment.