Skip to content

Commit

Permalink
add posibility to run zammad without elasticsearch (#75)
Browse files Browse the repository at this point in the history
* add posibility to run zammad without elasticsearch

To run zammad without elasticsearch, add following snippet to your
values.yaml file

```yaml
elasticsearch:
  enabled: false
  enableInitialisation: false
``

* bump chart
  • Loading branch information
grafjo authored Jan 9, 2021
1 parent 1061e7b commit cbedc59
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion zammad/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v2
name: zammad
version: 3.1.0
version: 3.2.0
appVersion: 3.6.0
description: Zammad is a web based open source helpdesk/customer support system with many features to manage customer communication via several channels like telephone, facebook, twitter, chat and e-mails.
home: https://zammad.org
Expand Down
3 changes: 2 additions & 1 deletion zammad/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ The following table lists the configurable parameters of the zammad chart and th
| `nodeSelector` | Node Selector | `{}` |
| `tolerations` | Tolerations | `[]` |
| `affinity` | Affinity | `{}` |
| `elasticsearch.enabled` | Use Elasticsearch dependency | `true` |
| `elasticsearch.enabled` | Use Elasticsearch chart dependency | `true` |
| `elasticsearch.enableInitialisation` | Run zammad specific Elasticsearch initialisation | `true` |
| `elasticsearch.image` | Elasticsearch docker image | `zammad/zammad-docker-compose` |
| `elasticsearch.imageTag` | Elasticsearch docker image tag | `zammad-elasticsearch-3.6.0-1` |
| `elasticsearch.clusterName` | Elasticsearch cluster name | `zammad` |
Expand Down
2 changes: 2 additions & 0 deletions zammad/templates/configmap-init.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ metadata:
labels:
{{- include "zammad.labels" . | nindent 4 }}
data:
{{ if .Values.elasticsearch.enableInitialisation }}
elasticsearch-init: |-
#!/bin/bash
set -e
Expand All @@ -17,6 +18,7 @@ data:
bundle exec rake searchindex:rebuild
{{ end }}
echo "elasticsearch init complete :)"
{{ end }}
postgresql-init: |-
#!/bin/bash
set -e
Expand Down
2 changes: 2 additions & 0 deletions zammad/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ spec:
mountPath: /docker-entrypoint.sh
readOnly: true
subPath: postgresql-init
{{ if .Values.elasticsearch.enableInitialisation }}
- name: elasticsearch-init
image: {{ .Values.image.repository }}:{{if eq .Values.image.repository "zammad/zammad-docker-compose"}}zammad-{{ end }}{{ .Values.image.tag }}
imagePullPolicy: {{ .Values.image.pullPolicy }}
Expand All @@ -80,6 +81,7 @@ spec:
mountPath: /docker-entrypoint.sh
readOnly: true
subPath: elasticsearch-init
{{ end }}
containers:
- name: {{ .Chart.Name }}-nginx
image: {{ .Values.image.repository }}:{{if eq .Values.image.repository "zammad/zammad-docker-compose"}}zammad-{{ end }}{{ .Values.image.tag }}
Expand Down
3 changes: 3 additions & 0 deletions zammad/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,10 @@ affinity: {}


elasticsearch:
# enable / disable elasticsearch chart dependency
enabled: true
# enable / disable zammad specific elasticsearch initialisation - disable this to run zammad without elasticsearch
enableInitialisation: true
image: "zammad/zammad-docker-compose"
imageTag: "zammad-elasticsearch-3.6.0-1"
clusterName: zammad
Expand Down

0 comments on commit cbedc59

Please sign in to comment.