Creating a new Search application service
Learn how to create additional search services to use with the HCL Compass helm chart.
Before you begin
- Untar the HCL Compass solution
chart .tgz
file.
$ tar xzvf <hcl-cpmpass-solution-tgz-file> - Move the /charts/hcl-compass/
directory.
$ cd <hcl-cpmpass-solution-tgz-folder>/charts/hcl-compass $ ls Chart.yaml licenses templates values.yaml
About this task
hcl-compass-search-app3.service and you will add it to the HCL Compass Helm chart.Procedure
-
Go to the /hcl-compass/template directory, copy the
search-app1-service.yamlfile to a new file namedsearch-app3-service.yaml. Edit thesearch-app3-service.yamlfile and replace app1 with app3 everywhere in the file. -
Go to the /hcl-compass/template directory, copy the
search-app1-deployment.yamlfile to a new file namedsearch-app3-deployment.yaml. Edit thesearch-app3-deployment.yamlfile and replace app1 with app3 everywhere in the file. -
Go to the /hcl-compass/template directory, copy the
search-app1-secrets.yamlfile to a new file namedsearch-app3-secrets.yaml. Edit thesearch-app3-secrets.yamlfile and replace app1 with app3 everywhere in the file. -
Go to the /hcl-compass/template directory, copy the
search-app1-pvc.yamlfile to a new file namedsearch-app3-pvc.yaml. Edit thesearch-app3-pvc.yamlfile and replace app1 with app3 everywhere in the file. -
Update the search-confimap.yaml file to include the following
searchapp3information:data: searchHostnames: |- ("{{ .Values.searchapp3.hostname }} {{ .Values.searchapp3.port }}) -
Update the /hcl-compass/template/compass-statefulset.yaml file by adding the
hcl-compass-search-app3.serviceto theinitContainers:* key:{{- if .Values.searchapp3.service }} - name: init-mysearchapp3service image: busybox:1.28 env: - name: searchapp3service value: {{ include "hcl-compass.fullname" . }}-search-app3 command: ['sh', '-c', "until nslookup $(searchapp3service).$(cat /var/run/secrets/kubernetes.io/serviceaccount/namespace).svc.cluster.local; do echo waiting for $(searchapp3service); sleep 2; done"] {{- end }} -
Create a new yaml file named search3-values.yaml and paste the
following
searchapp3: service: true replicaCount: 1 # The replicaCount that can be 1 to n hostname: search-app3 # Host name of the docker container runs the Searchapp3 feature configSet: (“-username <Username> -password <User password> -dbset <dbset_name> -userdb <User database> -searchPort <Search_port_number>”) ports: - 8985 # Search port number. db: # Database connection setting connectionSet: ("-v <db_vendor> -d <db_name> -s <db_server> -u <user> -p <password> -dbset <dbset_name>" -ip <Database_IP_Address>) properties: update: true valueSet: (\"-IndexWorkspace [true/false] -MaxHeapSize [val] -RetryAttempts [val] -RetryAttemptsPause [val] -IncrIndexMaxHeapSize [val] -FullIndexMaxHeapSize [val] -ProcRetryAttempts [val] -ProcRetryAttemptsPause [val]\") - Add -f search3-values.yaml to the helm install or helm upgrade command.