Problem beim ändern der Zeitzone

dimanche 26 novembre 2017

Hallo Leute,

ich möchte in einem Dockerbuild die Zeitzone des Images gleich automatisch anpassen.
Dazu führe ich folgende Schritte durch

Code:

root@0246a2ea9609:/start# cat /etc/timezone
Europe/Berlin
root@0246a2ea9609:/start# dpkg-reconfigure -f noninteractive tzdata

Current default time zone: 'Etc/UTC'
Local time is now:      Sun Nov 26 12:10:49 UTC 2017.
Universal Time is now:  Sun Nov 26 12:10:49 UTC 2017.

root@0246a2ea9609:/start# cat /etc/timezone
Etc/UTC

Wie man sieht ändert er die Zeitzone auf Etc/UTC

Bei manueller Änderung klappt alles wie es sollte.
Code:

root@0246a2ea9609:/start# dpkg-reconfigure tzdata
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
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  2. America  3. Antarctica  4. Australia  5. Arctic  6. Asia  7. Atlantic  8. Europe  9. Indian  10. Pacific  11. SystemV  12. US  13. Etc
Geographic area: 8

Please select the city or region corresponding to your time zone.

  1. Amsterdam  8. Bratislava  15. Dublin      22. Kaliningrad  29. Madrid    36. Oslo      43. San_Marino  50. Tallinn    57. Vienna
  2. Andorra    9. Brussels    16. Gibraltar    23. Kiev        30. Malta      37. Paris      44. Sarajevo    51. Tirane    58. Vilnius
  3. Astrakhan  10. Bucharest  17. Guernsey    24. Kirov        31. Mariehamn  38. Podgorica  45. Saratov    52. Tiraspol  59. Volgograd
  4. Athens    11. Budapest    18. Helsinki    25. Lisbon      32. Minsk      39. Prague    46. Simferopol  53. Ulyanovsk  60. Warsaw
  5. Belfast    12. Busingen    19. Isle_of_Man  26. Ljubljana    33. Monaco    40. Riga      47. Skopje      54. Uzhgorod  61. Zagreb
  6. Belgrade  13. Chisinau    20. Istanbul    27. London      34. Moscow    41. Rome      48. Sofia      55. Vaduz      62. Zaporozhye
  7. Berlin    14. Copenhagen  21. Jersey      28. Luxembourg  35. Nicosia    42. Samara    49. Stockholm  56. Vatican    63. Zurich
Time zone: 7


Current default time zone: 'Europe/Berlin'
Local time is now:      Sun Nov 26 13:12:21 CET 2017.
Universal Time is now:  Sun Nov 26 12:12:21 UTC 2017.

root@0246a2ea9609:/start#

nun ist es wie es sollte, da es aber ein automatisch build werden soll möchte ich verständlicherweise nicht nach jedem build noch manuell das image anpassen.

Hat jemand einen Tipp für mich? normalerweise sollte es ja mit
Code:

echo "Europe/Berlin" > /etc/timezone; dpkg-reconfigure -f noninteractive tzdata
erledigt sein, ist es aber leider nicht.

Danke für die hilfe.

Durchhalten shb


0 commentaires:

Enregistrer un commentaire

 

Lorem

Ipsum

Dolor