Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a filter for kubernetes.master logs. #11

Open
mmmmmmpc opened this issue Aug 3, 2017 · 2 comments
Open

Create a filter for kubernetes.master logs. #11

mmmmmmpc opened this issue Aug 3, 2017 · 2 comments
Assignees

Comments

@mmmmmmpc
Copy link
Collaborator

mmmmmmpc commented Aug 3, 2017

Create a filter for kubernetes.master logs.

Initial test may be the ones with "GET /api" in it.

@amitkumarj441
Copy link
Owner

@mperezco Please have a look at our fluentd filter.

@amitkumarj441
Copy link
Owner

@mperezco Please suggest here if I'd able to get the logs under Kibana

kubernetes-filter.conf: |
<filter kubernetes.**>
type kubernetes_metadata
merge_json_log true
preserve_json_log true
</filter>
<filter kubernetes.**>
@type record_transformer
enable_ruby true
<record>
kubernetes_namespace_container_name ${record["kubernetes"]["namespace_name"]}.${record["kubernetes"]["container_name"]}
</record>
</filter>
<match kubernetes.**>
@type rewrite_tag_filter
rewriterule1 kubernetes_namespace_container_name ^(.+)$ kube.$1
</match>
<filter kube.**>
@type record_transformer
remove_keys kubernetes_namespace_container_name
</filter>
<filter kube.kube-system.**>
type parser
format kubernetes
reserve_data true
key_name log
suppress_parse_error_log true
</filter>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants