I'm running Docker desktop community 2.0.3. I ran the official nginx and Apache HTTP server containers from docker hub (hub.docker.com). The container images are based on Debian 9. Then, I tried to install Debian standard system utilities using tasksel. I opened a terminal in the container using:

docker exec -ti container_id bash

I tried to run the tasksel installation

# tasksel install standard
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
Installing packages


The issues are:

  • It doesn't open the tasksel TUI (text user interface) as seen in the screenshot.
  • I get the errors above and it doesn't finish installation.

Docker desktop is installed on macOS 10.12



To use tasksel, you need to install dialog; in your container:

apt update && apt install -y dialog tasksel


tasksel install standard

will work, with the usual interface.

You don’t need to pass the TERM variable in.

Many of the standard utilities aren’t much use in a container, however if I were to do this, I would use aptitude instead of tasksel:

apt update && apt install -y aptitude && \
aptitude install -y ~pstandard ~prequired ~pimportant
| improve this answer | |

Turns out ncurses requires this command: https://stackoverflow.com/a/38774123/3341782 Not sure if there's a better solution.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.