-
Notifications
You must be signed in to change notification settings - Fork 98
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
Add support for CRI-O format #80
Conversation
Support container logs from nodes running with docker or with crio (https://cri-o.io/). Signed-off-by: Jonas Rutishauser <jonas.rutishauser@css.ch>
Hi @jonasrosland, I have not environment with cri-o to test this. Is your change compatible with docker AND crio? Would Docker container logs still be processed correctly? |
Yes it is compatible with docker and cri-o. The docker container logs should still be parsed the same way. The multiline parser contains 2 patterns which are tried one after the other:
The next filter is only for cri-o logs and it will concatenate all partials. kube-fluentd-operator/config-reloader/templates/kubernetes.conf Lines 23 to 31 in d79805d
Then there is a filter which parses the json of docker logs. kube-fluentd-operator/config-reloader/templates/kubernetes.conf Lines 34 to 44 in d79805d
The only small issue with this solution is in cri-o logs. |
Signed-off-by: Jonas Rutishauser <jonas.rutishauser@css.ch>
I have tested with the following input:
The output just after the second filter was the following:
|
Thank you for your PR! |
Support container logs from nodes running with docker or with crio (https://cri-o.io/).