Am 6/17/20 um 2:48 PM schrieb Oguz Bektas: >>> diff --git a/src/PVE/LXC/Setup.pm b/src/PVE/LXC/Setup.pm >>> index c738e64..0e07796 100644 >>> --- a/src/PVE/LXC/Setup.pm >>> +++ b/src/PVE/LXC/Setup.pm >>> @@ -5,6 +5,8 @@ use warnings; >>> use POSIX; >>> use PVE::Tools; >>> >>> +use Cwd 'abs_path'; >>> + >>> use PVE::LXC::Setup::Debian; >>> use PVE::LXC::Setup::Ubuntu; >>> use PVE::LXC::Setup::CentOS; >>> @@ -103,6 +105,7 @@ sub new { >>> >>> # Cache some host files we need access to: >>> $plugin->{host_resolv_conf} = PVE::INotify::read_file('resolvconf'); >>> + $plugin->{host_localtime} = abs_path('/etc/localtime'); >> Hmm, I'd not save that in the $plugin, makes no sense to me. >> I mean, I see where this comes from but that also doesn't makes much sense >> to me. >> >> This isn't both expected to be used often, so just using it directly without >> cache >> or at least cache only if at least used once would be nicer IMO. > > this was the simplest way i found, and it's just caching a ~50 byte > string (/etc/localtime symlink) to be used in the setup. > > how else can i access that in the setup routines > which are running in CT rootfs? > >
OK, then lets keep it your proposed way for now. _______________________________________________ pve-devel mailing list pve-devel@pve.proxmox.com https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel