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

filebeat kubernetes module not picking up initContainers metadata #4825

Closed
djschny opened this issue Aug 3, 2017 · 0 comments · Fixed by #4890
Closed

filebeat kubernetes module not picking up initContainers metadata #4825

djschny opened this issue Aug 3, 2017 · 0 comments · Fixed by #4890

Comments

@djschny
Copy link

djschny commented Aug 3, 2017

  • Version: 6.0.0-alpha2
  • Operating System: GKE container OS

In Kubernetes you Init Containers can be specified for a Deployment. Unfortunately it appears that the kubernetes metadata fields are not showing up for logs from an init-container in a pod. The logs from the main app container (in this case Nginx) are being populated fine. See the following screenshot for an example. The sleep and terminating log messages were from an init container.

image

Originally reported / discussed below:

https://discuss.elastic.co/t/kubernetes-metadata-not-showing-up-for-init-containers/95620

Below can be used to reproduce.

apiVersion: apps/v1beta1
kind: Deployment
metadata:
  name: nginx
spec:
  replicas: 3
  template:
    metadata:
      labels:
        app: nginx
    spec:
      containers:
      - name: nginx
        image: nginx:1.13.1
        ports:
        - containerPort: 80
      initContainers:
      - name: slowness
        image: busybox
        command: ['sh', '-c', 'echo "Sleeping 10 sceonds..." && sleep 10'] 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants