Please can someone confirm if this is a valid Elasticsearch deployment for Openshift?
Please advise as I am stuck since couple of days.
---
apiVersion: route.openshift.io/v1
kind: Route
metadata:
name: elasticsearch
spec:
#host: elasticsearch.example.com # override if you don't want to use the host that is automatically generated by OpenShift (<route-name>[-<namespace>].<suffix>)
tls:
termination: passthrough # Elasticsearch is the TLS endpoint
insecureEdgeTerminationPolicy: Redirect
to:
kind: Service
name: elasticsearch-es-http
---
apiVersion: elasticsearch.k8s.elastic.co/v1
kind: Elasticsearch
metadata:
name: elasticsearch
spec:
version: 7.17.0
image: docker-eu.artifactory.swg-devops.com/sec-yoda-team-docker-local/pti/elasticsearch-gcs:7.17.0
secureSettings:
- secretName: jfrog
nodeSets:
- name: master
count: 1
config:
node.master: true
node.data: false
podTemplate:
spec:
securityContext:
runAsUser: 1234
fsGroup: 1234
initContainers:
- name: sysctl
securityContext:
privileged: true
command: ['sh', '-c', 'sysctl -w vm.max_map_count=262144']
containers:
- name: elasticsearch
env:
- name: ES_JAVA_OPTS
value: -Xms2g -Xmx2g
resources:
requests:
cpu: 2
memory: 8Gi
limits:
cpu: 3
memory: 10Gi
- name: data
count: 3
config:
node.master: false
node.data: true
node.attr.date: hot
podTemplate:
spec:
securityContext:
runAsUser: 1234
fsGroup: 1234
initContainers:
- name: sysctl
securityContext:
privileged: true
command: ['sh', '-c', 'sysctl -w vm.max_map_count=262144']
containers:
- name: elasticsearch
env:
- name: ES_JAVA_OPTS
value: -Xms2g -Xmx2g
resources:
requests:
cpu: 2
memory: 8Gi
limits:
cpu: 3
memory: 10Gi
volumeClaimTemplates:
- metadata:
name: elasticsearch-data
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 100Gi
storageClassName: ibmc-file-silver