Kibana: Add support for arbitrary object definitions via
overrides This allows for customizing the indexes required by different deployment targets instead of assuming all indexes are common for every type of deployment. Change-Id: Iae9a35462400f7c8612ee7d0b49bfd6a20d3120c
This commit is contained in:
parent
99c09daa74
commit
e966ae6ba8
@ -14,13 +14,14 @@ limitations under the License.
|
|||||||
*/}}
|
*/}}
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
{{- range .Values.conf.create_kibana_indexes.indexes }}
|
{{- range $objectType, $indices := .Values.conf.create_kibana_indexes.indexes }}
|
||||||
|
{{- range $indices }}
|
||||||
curl -K- <<< "--user ${ELASTICSEARCH_USERNAME}:${ELASTICSEARCH_PASSWORD}" \
|
curl -K- <<< "--user ${ELASTICSEARCH_USERNAME}:${ELASTICSEARCH_PASSWORD}" \
|
||||||
-XPOST "${KIBANA_ENDPOINT}/api/saved_objects/index-pattern/{{ . }}*" -H 'kbn-xsrf: true' \
|
-XPOST "${KIBANA_ENDPOINT}/api/saved_objects/index-pattern/{{ . }}*" -H 'kbn-xsrf: true' \
|
||||||
-H 'Content-Type: application/json' -d \
|
-H 'Content-Type: application/json' -d \
|
||||||
'{"attributes":{"title":"{{ . }}-*","timeFieldName":"@timestamp"}}'
|
'{"attributes":{"title":"{{ . }}-*","timeFieldName":"@timestamp"}}'
|
||||||
|
{{- end }}
|
||||||
{{ end }}
|
{{- end }}
|
||||||
|
|
||||||
curl -K- <<< "--user ${ELASTICSEARCH_USERNAME}:${ELASTICSEARCH_PASSWORD}" \
|
curl -K- <<< "--user ${ELASTICSEARCH_USERNAME}:${ELASTICSEARCH_PASSWORD}" \
|
||||||
-XPOST "${KIBANA_ENDPOINT}/api/kibana/settings/defaultIndex" -H 'kbn-xsrf: true' \
|
-XPOST "${KIBANA_ENDPOINT}/api/kibana/settings/defaultIndex" -H 'kbn-xsrf: true' \
|
||||||
|
@ -280,10 +280,12 @@ conf:
|
|||||||
enabled: true
|
enabled: true
|
||||||
version: 7.1.0
|
version: 7.1.0
|
||||||
indexes:
|
indexes:
|
||||||
- logstash
|
base:
|
||||||
- openstack
|
- logstash
|
||||||
- journal
|
- journal
|
||||||
- kernel
|
- kernel
|
||||||
|
application:
|
||||||
|
- openstack
|
||||||
default_index: logstash
|
default_index: logstash
|
||||||
|
|
||||||
endpoints:
|
endpoints:
|
||||||
|
Loading…
Reference in New Issue
Block a user