all lists on lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [RFC installer] install: do not create deprecated /etc/timezone
@ 2025-08-05 21:40 Stoiko Ivanov
  2025-09-17 16:08 ` [pve-devel] applied: " Thomas Lamprecht
  0 siblings, 1 reply; 2+ messages in thread
From: Stoiko Ivanov @ 2025-08-05 21:40 UTC (permalink / raw)
  To: pve-devel

starting with  tzdata version 2024b-5 [0] the package does not create
/etc/timezone anymore (background is quite well explained in
/usr/share/doc/tzdata/NEWS.Debian.gz:
```
Previously, the tzdata package in Debian used the /etc/timezone file to
configure the system's timezone. This method is not supported by systemd
and certain desktop environments, which instead only change the
/etc/localtime symlink to point to a file in /usr/share/zoneinfo.
....
In a future release, the /etc/timezone file will be automatically
removed ... The debian-installer from Trixie also no longer
creates this file.
```
align our installer with debian's installer.

[0] https://metadata.ftp-master.debian.org/changelogs//main/t/tzdata/tzdata_2025b-4_changelog
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
---
I would NOT recommend adding this patch now - we'd need to check where our
code relies on /etc/timezone being present (PVE/INotify.pm creates it IIRC,
proxmox-time create and proxmox-backup have a fallback to /etc/localtime) -
but that was just a very cursory glance at a grep '/etc/timezone' in my
source-dir).

 Proxmox/Install.pm | 1 -
 1 file changed, 1 deletion(-)

diff --git a/Proxmox/Install.pm b/Proxmox/Install.pm
index 9cb88bc..fb23f7f 100644
--- a/Proxmox/Install.pm
+++ b/Proxmox/Install.pm
@@ -1299,7 +1299,6 @@ _EOD
         my $timezone = Proxmox::Install::Config::get_timezone();
         unlink("$targetdir/etc/localtime");
         symlink("/usr/share/zoneinfo/$timezone", "$targetdir/etc/localtime");
-        file_write_all("$targetdir/etc/timezone", "$timezone\n");
 
         unlink "$targetdir/etc/mailname";
         $postfix_main_cf =~ s/__FQDN__/${hostname}.${domain}/;
-- 
2.39.5



_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [pve-devel] applied: [RFC installer] install: do not create deprecated /etc/timezone
  2025-08-05 21:40 [pve-devel] [RFC installer] install: do not create deprecated /etc/timezone Stoiko Ivanov
@ 2025-09-17 16:08 ` Thomas Lamprecht
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Lamprecht @ 2025-09-17 16:08 UTC (permalink / raw)
  To: pve-devel, Stoiko Ivanov

On Tue, 05 Aug 2025 23:40:06 +0200, Stoiko Ivanov wrote:
> starting with  tzdata version 2024b-5 [0] the package does not create
> /etc/timezone anymore (background is quite well explained in
> /usr/share/doc/tzdata/NEWS.Debian.gz:
> ```
> Previously, the tzdata package in Debian used the /etc/timezone file to
> configure the system's timezone. This method is not supported by systemd
> and certain desktop environments, which instead only change the
> /etc/localtime symlink to point to a file in /usr/share/zoneinfo.
> ....
> In a future release, the /etc/timezone file will be automatically
> removed ... The debian-installer from Trixie also no longer
> creates this file.
> ```
> align our installer with debian's installer.
> 
> [...]

Applied, thanks!

[1/1] install: do not create deprecated /etc/timezone
      commit: 037525b92039465d6ee830ad4efa86629e0f408c


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-09-17 16:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-08-05 21:40 [pve-devel] [RFC installer] install: do not create deprecated /etc/timezone Stoiko Ivanov
2025-09-17 16:08 ` [pve-devel] applied: " Thomas Lamprecht

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal