-
Notifications
You must be signed in to change notification settings - Fork 3k
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
operator: cilium-operator terminates when Kubernetes libraries try to log a non-existent directory #7006
Comments
Fixed by #7007 |
Reopening; fix in #7007 was not enough. The problem with getting this to work gracefully is that the default golang flags library does not play nicely with the pflags library / cobra. As a stop-gap, we can create the |
…rator `klog`, which is used by the Kubernetes libraries consumed by `cilium-operator`, always tries to log to a file in `/tmp`. Since the `cilium-operator` container image is built off of `scratch`, such a directory does not exist. If the directory does not exist, `klog` exits and causes `cilium-operator` to crash. To not crash, do not log to any directories, and instead set the `logtostderr` value within `klog` to `true` so that it does not log to a directory. Fixes: #7006 Signed-off by: Ian Vernon <ian@cilium.io>
Update to anyone that his this issue: the issue was that I was trying to configure Credit to @aanm for the correct fix. |
…rator `klog`, which is used by the Kubernetes libraries consumed by `cilium-operator`, always tries to log to a file in `/tmp`. Since the `cilium-operator` container image is built off of `scratch`, such a directory does not exist. If the directory does not exist, `klog` exits and causes `cilium-operator` to crash. To not crash, do not log to any directories, and instead set the `logtostderr` value within `klog` to `true` so that it does not log to a directory. Fixes: #7006 Signed-off by: Ian Vernon <ian@cilium.io>
…rator [ upstream commit eee2e8d ] `klog`, which is used by the Kubernetes libraries consumed by `cilium-operator`, always tries to log to a file in `/tmp`. Since the `cilium-operator` container image is built off of `scratch`, such a directory does not exist. If the directory does not exist, `klog` exits and causes `cilium-operator` to crash. To not crash, do not log to any directories, and instead set the `logtostderr` value within `klog` to `true` so that it does not log to a directory. Fixes: cilium#7006 Signed-off by: Ian Vernon <ian@cilium.io> Signed-off-by: Eloy Coto <eloy.coto@gmail.com>
…rator [ upstream commit eee2e8d ] `klog`, which is used by the Kubernetes libraries consumed by `cilium-operator`, always tries to log to a file in `/tmp`. Since the `cilium-operator` container image is built off of `scratch`, such a directory does not exist. If the directory does not exist, `klog` exits and causes `cilium-operator` to crash. To not crash, do not log to any directories, and instead set the `logtostderr` value within `klog` to `true` so that it does not log to a directory. Fixes: #7006 Signed-off by: Ian Vernon <ian@cilium.io> Signed-off-by: Eloy Coto <eloy.coto@gmail.com>
The following error caused the cilium-operator to exit:
Related-issues from other consumers of the client-go library have hit this too: traefik/traefik#1817
We should implement a similar fix in the cilium-operator.
The text was updated successfully, but these errors were encountered: