Of courses,
filebeat.inputs:
- type: container
paths:- /var/log/containers/*.log
processors: - add_kubernetes_metadata:
host: ${NODE_NAME}
matchers:- logs_path:
logs_path: "/var/log/containers/"
- logs_path:
- /var/log/containers/*.log
/# To enable hints based autodiscover, remove filebeat.inputs configuration and uncomment this:
/filebeat.autodiscover:
/# providers:
/# - type: kubernetes
/# node: ${NODE_NAME}
/# hints.enabled: true
/# hints.default_config:
/# type: container
/# paths:
/# - /var/log/containers/*${data.kubernetes.container.id}.log
processors:
- add_cloud_metadata:
- add_host_metadata:
cloud.id: ${ELASTIC_CLOUD_ID}
cloud.auth: ${ELASTIC_CLOUD_AUTH}
output.elasticsearch:
hosts: ["elasticsearch-client.efk-xpack.svc.cluster.local:9200"]
username: "${ELASTICSEARCH_USERNAME}"
password: "${ELASTICSEARCH_PASSWORD}"