-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
python is not configured for tkinter #122
Comments
@tianon @yosifkit any thoughts on this? I can submit a PR if there's no objection to adding tk to the official images. I think the -dev package is required for the build, and the lib is required for the runtime. My plan to fix would be to install tk and tk-dev from the apt/apk, removing tk-dev after the building python. |
99% of Docker files shouldn't need the Tkinter files, as Docker isn't designed to handle GUIs (I believe, correct me if I'm wrong). You should be able to install Tkinter in a separate Dockerfile that extends the Python ones provided here.
|
@kevin-brown the tkinter module is defined CPython and is complied into python. https://wiki.python.org/moin/TkInter I'm not aware of any other way to build/install it as an |
Since this must be complied into python and cannot be added later, I propose a possible solution to emphasize the "include everything" default tag vs the tiny
Size differences:
|
SGTM!
|
so whats the solution? How do we get the library we need? |
whats wrong with
|
We don't use the Debian/apt-provided python, but compile and install it from upstream source directly. The |
@yosifkit how do I do that? |
@brando90, it is already installed: #127 (comment). If you need help getting it to connect to your display, it'd be better to post questions like that in the Docker Community Forums, the Docker Community Slack, or Stack Overflow. |
Is tkinter purposefully omitted? It seems like the only way to enable it is to rebuild from source.
Adding
apt-get update && apt-get install -y --no-install-recommends tk-dev && rm -r /var/lib/apt/lists/*
to the current Dockerfiles appears to resolve the issue, but adds ~20MB to the resulting image.Current behavior:
The text was updated successfully, but these errors were encountered: