Skip to content
This repository has been archived by the owner on May 16, 2023. It is now read-only.

[logstash] use new elasticsearch credentials #1402

Merged
merged 2 commits into from
Oct 13, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions logstash/examples/elasticsearch/test/goss.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ http:
http://elasticsearch-master:9200/_cat/indices:
status: 200
timeout: 2000
username: "{{ .Env.ELASTICSEARCH_USERNAME }}"
password: "{{ .Env.ELASTICSEARCH_PASSWORD }}"
body:
- "logstash"

Expand Down
21 changes: 20 additions & 1 deletion logstash/examples/elasticsearch/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,23 @@ logstashConfig:
logstashPipeline:
uptime.conf: |
input { exec { command => "uptime" interval => 30 } }
output { elasticsearch { hosts => ["http://elasticsearch-master:9200"] index => "logstash" } }
output {
elasticsearch {
hosts => ["http://elasticsearch-master:9200"]
user => '${ELASTICSEARCH_USERNAME}'
password => '${ELASTICSEARCH_PASSWORD}'
index => "logstash"
}
}

extraEnvs:
- name: "ELASTICSEARCH_USERNAME"
valueFrom:
secretKeyRef:
name: elasticsearch-master-credentials
key: username
- name: "ELASTICSEARCH_PASSWORD"
valueFrom:
secretKeyRef:
name: elasticsearch-master-credentials
key: password
8 changes: 4 additions & 4 deletions logstash/examples/security/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@ secretMounts:
path: /usr/share/logstash/config/certs

extraEnvs:
- name: 'ELASTICSEARCH_USERNAME'
- name: "ELASTICSEARCH_USERNAME"
valueFrom:
secretKeyRef:
name: elastic-credentials
name: security-master-credentials
key: username
- name: 'ELASTICSEARCH_PASSWORD'
- name: "ELASTICSEARCH_PASSWORD"
valueFrom:
secretKeyRef:
name: elastic-credentials
name: security-master-credentials
key: password