困ったこと
0からdockerイメージを作っていて、いろいろパッケージをインストールさせていたら
ビルド中にtime zoneの選択肢が表示されて、進まなくなってしまいました。
エラーではなさそうなのですが・・・。
事象
ターミナルに表示されているメッセージは次のとおりです。
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:
数字を押しても、Enterキーを押しても先に進まなくなってしまいます。
解決方法
gitのインストールコマンドよりも前に次にDEBIAN_FRONTEDの設定を実行します。
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update \
&& apt-get -y install git
まとめ
dockerfileでgitをapt-get install するときは
DEBIAN_FRONTED=noninteractive を先に設定しましょう。