diff --git a/stable/elastalert/Chart.yaml b/stable/elastalert/Chart.yaml index 5065d1ac72..0d82cd0c11 100644 --- a/stable/elastalert/Chart.yaml +++ b/stable/elastalert/Chart.yaml @@ -1,12 +1,14 @@ description: ElastAlert is a simple framework for alerting on anomalies, spikes, or other patterns of interest from data in Elasticsearch. name: elastalert -version: 0.1.1 -appVersion: 0.1.21 +version: 0.1.2 +appVersion: 0.1.29 icon: https://static-www.elastic.co/assets/blteb1c97719574938d/logo-elastic-elasticsearch-lt.svg sources: -- https://github.com/krizsan/elastalert-docker +- https://github.com/jertel/elastalert-docker - https://github.com/Yelp/elastalert maintainers: - name: pickledrick email: 9246508+pickledrick@users.noreply.github.com + - name: jertel + email: jertel@codesim.com engine: gotpl diff --git a/stable/elastalert/README.md b/stable/elastalert/README.md index a54b304362..3116e040b5 100644 --- a/stable/elastalert/README.md +++ b/stable/elastalert/README.md @@ -32,11 +32,13 @@ The command removes all the Kubernetes components associated with the chart and | Parameter | Description | Default | |---------------------------|-----------------------------------------------------|-----------------------------------| -| `image.repository` | docker image | quay.io/pickledrick/elastalert | -| `image.tag` | docker image tag | latest | +| `image.repository` | docker image | jertel/elastalert-docker | +| `image.tag` | docker image tag | 0.1.29 | | `image.pullPolicy` | image pull policy | IfNotPresent | | `replicaCount` | number of replicas to run | 1 | | `elasticsearch.host` | elasticsearch endpoint to use | elasticsearch | | `elasticsearch.port` | elasticsearch port to use | 80 | | `resources` | Container resource requests and limits | {} | | `rules` | Rule and alert configuration for Elastalert | {} example shown in values.yaml | +| `runIntervalMins` | Default interval between alert checks, in minutes | 1 | +| `bufferTimeMins` | Default rule buffer time, in minutes | 15 | diff --git a/stable/elastalert/templates/config.yaml b/stable/elastalert/templates/config.yaml index 8d4853ccc5..98139250ed 100644 --- a/stable/elastalert/templates/config.yaml +++ b/stable/elastalert/templates/config.yaml @@ -1,3 +1,4 @@ +apiVersion: v1 kind: ConfigMap metadata: name: {{ template "elastalert.fullname" . }}-config @@ -12,42 +13,11 @@ data: rules_folder: /opt/rules scan_subdirectories: false run_every: - minutes: 1 + minutes: {{ .Values.runIntervalMins }} buffer_time: - minutes: 15 + minutes: {{ .Values.bufferTimeMins }} es_host: {{ .Values.elasticsearch.host }} es_port: {{ .Values.elasticsearch.port }} writeback_index: elastalert_status alert_time_limit: - days: 2 - elastalert_supervisord: |- - [unix_http_server] - file=/var/run/elastalert_supervisor.sock - - [supervisord] - logfile=/opt/logs/elastalert_supervisord.log - logfile_maxbytes=1MB - logfile_backups=2 - loglevel=debug - nodaemon=false - directory=%(here)s - - [rpcinterface:supervisor] - supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface - - [supervisorctl] - serverurl=unix:///var/run/elastalert_supervisor.sock - - [program:elastalert] - # running globally - command = elastalert --config /opt/config/elastalert_config.yaml --verbose - # (alternative) using virtualenv - # command=/path/to/venv/bin/elastalert --config /path/to/config.yaml --verbose - process_name=elastalert - autorestart=true - startsecs=15 - stopsignal=INT - stopasgroup=true - killasgroup=true - stderr_logfile=/opt/logs/elastalert_stderr.log - stderr_logfile_maxbytes=5MB \ No newline at end of file + days: 2 \ No newline at end of file diff --git a/stable/elastalert/templates/deployment.yaml b/stable/elastalert/templates/deployment.yaml index 0ec042363a..88a1bebb91 100644 --- a/stable/elastalert/templates/deployment.yaml +++ b/stable/elastalert/templates/deployment.yaml @@ -1,3 +1,4 @@ +{{ if .Values.elasticsearch.host }} apiVersion: apps/v1beta1 kind: Deployment metadata: @@ -21,11 +22,6 @@ spec: - name: elastalert image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" imagePullPolicy: {{ .Values.image.pullPolicy }} - env: - - name: ELASTICSEARCH_HOST - value: {{ .Values.elasticsearch.host }} - - name: ELASTICSEARCH_PORT - value: {{ .Values.elasticsearch.port | quote }} volumeMounts: - name: config mountPath: '/opt/config' @@ -49,5 +45,4 @@ spec: items: - key: elastalert_config path: elastalert_config.yaml - - key: elastalert_supervisord - path: elastalert_supervisord.conf +{{- end }} \ No newline at end of file diff --git a/stable/elastalert/templates/rules.yaml b/stable/elastalert/templates/rules.yaml index ee0693af4e..1e4afd4573 100644 --- a/stable/elastalert/templates/rules.yaml +++ b/stable/elastalert/templates/rules.yaml @@ -1,3 +1,4 @@ +apiVersion: v1 kind: ConfigMap metadata: name: {{ template "elastalert.fullname" . }}-rules diff --git a/stable/elastalert/values.yaml b/stable/elastalert/values.yaml index 114379d9cf..3797bf46d2 100644 --- a/stable/elastalert/values.yaml +++ b/stable/elastalert/values.yaml @@ -3,17 +3,23 @@ replicaCount: 1 # number of helm release revisions to retain revisionHistoryLimit: 5 +# Default internal between alert checks against the elasticsearch datasource, in minutes +runIntervalMins: 1 + +# Default rule buffer duration, in minutes +bufferTimeMins: 15 + image: # docker image - repository: quay.io/pickledrick/elastalert + repository: jertel/elastalert-docker # docker image tag - tag: stable + tag: 0.1.29 pullPolicy: IfNotPresent resources: {} elasticsearch: # elasticsearch endpoint e.g. (svc.namespace||svc) - host: elasticsearch + host: "" # elasticsearch port port: 80