kubefuse
kubefuse copied to clipboard
Doesn't seem to handle multi container pods in respect to logs
A single container pod's logs seems to work fine, but it looks like you might need to add a deeper hierarchy for containers. (the equiv. of kubectl logs podname -c containername).
But so far very fun work!
I see the same problem. Need to pass kubectl
the -c
flag in some cases:
$ cat ~/k8s/kube-system/pod/kube-dns-v11-19scr/logs
$
$ kubectl --namespace=kube-system logs kube-dns-v11-19scr
Error from server: a container name must be specified for pod kube-dns-v11-19scr, choose one of: [etcd kube2sky skydns healthz]
$ kubectl --namespace=kube-system logs -c etcd kube-dns-v11-19scr
2016-06-29 00:29:03.644732 I | etcdserver: start to snapshot (applied: 4810481, lastsnap: 4800480)
2016-06-29 00:29:03.705105 I | etcdserver: saved snapshot at index 4810481
2016-06-29 00:29:03.705411 I | etcdserver: compacted raft log at 4805481
...
Seems like the primary issue in resolving this is deciding on the proper directory hierarchy.
Yes indeed. I like the simplicity of having a single logs file, but maybe we could add extra folders or files when there is more than one container in the pod.
Since the pods need to have a name it may be as simple as naming the logs «log_container».