Simply use $ENV{HOME} instead.
use PVE::JSONSchema qw(register_standard_option get_standard_option);
use PVE::SectionConfig;
use PVE::Tools qw(file_get_contents file_set_contents);
use PVE::JSONSchema qw(register_standard_option get_standard_option);
use PVE::SectionConfig;
use PVE::Tools qw(file_get_contents file_set_contents);
sub config_filename {
my ($class) = @_;
sub config_filename {
my ($class) = @_;
- return File::HomeDir::home() . '/.pveclient';
+ my $home = $ENV{HOME};
+
+ die "environment HOME not set\n" if !defined($home);
+
+ return "$home/.pveclient";