-
Notifications
You must be signed in to change notification settings - Fork 607
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
Panic: not a console
, follow-up to #3297
#3433
Comments
Do you have any examples of how you wrap? |
Sorry, there is no workaround that I know of. |
Can I provide some additional information to help you fix the issue? Even if it is impossible to run top inside of the container, at least it shouldn't crash. |
Of course. |
What do you want me to do. Let me know if you want me to run debugging of some sort or test with some different version of nerdctl |
Ideally:
Thanks. |
As outlined in containerd#3433, containerd/console will panic on a call to console.Current(). This patch provides a simple consoleutil wrapper that will return an error instead. Note that part of containerd#3300 is being reverted, as no longer necessary. This patch does not try to be "smart" and does not check the status of stdin/out/err otherwise or if it is consistent with user provided flags, but merely ensures we do not crash. Signed-off-by: apostasie <[email protected]>
As outlined in containerd#3433, containerd/console will panic on a call to console.Current(). This patch provides a simple consoleutil wrapper that will return an error instead. Note that part of containerd#3300 is being reverted, as no longer necessary. This patch does not try to be "smart" and does not check the status of stdin/out/err otherwise or if it is consistent with user provided flags, but merely ensures we do not crash. Signed-off-by: apostasie <[email protected]>
As outlined in containerd#3433, containerd/console will panic on a call to console.Current(). This patch provides a simple consoleutil wrapper that will return an error instead. Note that part of containerd#3300 is being reverted, as no longer necessary. This patch does not try to be "smart" and does not check the status of stdin/out/err otherwise or if it is consistent with user provided flags, but merely ensures we do not crash. Signed-off-by: apostasie <[email protected]>
As outlined in containerd#3433, containerd/console will panic on a call to console.Current(). This patch provides a simple consoleutil wrapper that will return an error instead. Note that part of containerd#3300 is being reverted, as no longer necessary. This patch does not try to be "smart" and does not check the status of stdin/out/err otherwise or if it is consistent with user provided flags, but merely ensures we do not crash. Signed-off-by: apostasie <[email protected]>
Thank you for your work. I built and tested new code. It allows a container to continue. This said are there any plans to make nerdctl started container from systemd more pseudo-terminal friendly? |
@alitvak69 you are welcome! Roadmap questions should go to @AkihiroSuda or other maintainers. Cheers. |
As outlined in containerd#3433, containerd/console will panic on a call to console.Current(). This patch provides a simple consoleutil wrapper that will return an error instead. Note that part of containerd#3300 is being reverted, as no longer necessary. This patch does not try to be "smart" and does not check the status of stdin/out/err otherwise or if it is consistent with user provided flags, but merely ensures we do not crash. Signed-off-by: apostasie <[email protected]>
Description
As outlined in #3297, there are more places that are likely to panic when we do not have a tty.
While the patch in #3300 fixed it for
exec
for a specific use case, clearlyrun
can crash in the same circumstances.Suggestion is to wrap the third party term console library so that it returns an error we can check instead of crashing.
Steps to reproduce the issue
na
Describe the results you received and expected
na
What version of nerdctl are you using?
main
Are you using a variant of nerdctl? (e.g., Rancher Desktop)
None
Host information
No response
The text was updated successfully, but these errors were encountered: