How to write the Dockerfile that can pass yes to prompting license agreement?
- under Dockerfile directory,
docker build -t "{user}/{tags}" .
then build failed. docker logs {container id}
, show message as below:Preparing to unpack .../ttf-mscorefonts-installer_3.4+nmu1ubuntu2_all.deb ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline Configuring ttf-mscorefonts-installer TrueType core fonts for the Web EULA END-USER LICENSE AGREEMENT FOR MICROSOFT SOFTWARE ... Do you accept the EULA license terms? [yes/no]
Follow by discuession here issue: [16.04] debconf: delaying package configuration, since apt-utils is not installed.
I added these three lines of codes in Dockerfile:
Finally Successfully built the docker image !
You can write a
-y
at the end of your line in the Dockerfile.Example:
You can try this solution based on this: https://unix.stackexchange.com/a/106553
debconf
setting for the licenseYou might need to install
debconf-utils
fordebconf-set|get-selections
.