2

Part of my Dockerfile is as:

RUN apt-get install -yqq software-properties-common
RUN add-apt-repository ppa:ubuntugis/ppa && apt-get update -yqq
RUN apt-get install -yqq gdal-bin
RUN apt-get install -yqq postgis

I installed postgis repo, then installing postgis, but when it got to the installation step of postgis, I get this prompt on the screen & it's stuck there.

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 tzdata
------------------

Please select the geographic area in which you live. Subsequent configuration
questions will narrow this down by presenting a list of cities, representing
the time zones in which they are located.

  1. Africa      4. Australia  7. Atlantic  10. Pacific  13. Etc
  2. America     5. Arctic     8. Europe    11. SystemV
  3. Antarctica  6. Asia       9. Indian    12. US
Geographic area:

Does anyone has any idea??

Sollosa
  • 379
  • 4
  • 13

1 Answers1

3

Use RUN DEBIAN_FRONTEND=noninteractive apt-get install -yqq postgis when install postgis to suppress the dialog, or use ARG DEBIAN_FRONTEND=noninteractive which will also not persist to container but still have same effect.

Maybe also refers to https://github.com/docker/docker/issues/4032

atline
  • 28,355
  • 16
  • 77
  • 113