Pass what storage ID is being used to vzdump hook scripts
Signed-off-by: Mark Casey <markc@unifiedgroup.com>
This commit is contained in:
parent
d81a44e8e3
commit
5d7aff710e
@ -646,7 +646,7 @@ sub run_hook_script {
|
|||||||
|
|
||||||
local %ENV;
|
local %ENV;
|
||||||
|
|
||||||
foreach my $ek (qw(vmtype dumpdir hostname tarfile logfile)) {
|
foreach my $ek (qw(vmtype dumpdir hostname tarfile logfile storeid)) {
|
||||||
$ENV{uc($ek)} = $task->{$ek} if $task->{$ek};
|
$ENV{uc($ek)} = $task->{$ek} if $task->{$ek};
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -764,7 +764,7 @@ sub exec_backup_task {
|
|||||||
die "unable to create log file '$tmplog'";
|
die "unable to create log file '$tmplog'";
|
||||||
|
|
||||||
$task->{dumpdir} = $opts->{dumpdir};
|
$task->{dumpdir} = $opts->{dumpdir};
|
||||||
|
$task->{storeid} = $opts->{storage};
|
||||||
$task->{tmplog} = $tmplog;
|
$task->{tmplog} = $tmplog;
|
||||||
|
|
||||||
unlink $logfile;
|
unlink $logfile;
|
||||||
|
@ -29,6 +29,8 @@ if ($phase eq 'job-start' ||
|
|||||||
|
|
||||||
my $dumpdir = $ENV{DUMPDIR};
|
my $dumpdir = $ENV{DUMPDIR};
|
||||||
|
|
||||||
|
my $storeid = $ENV{STOREID};
|
||||||
|
|
||||||
my $hostname = $ENV{HOSTNAME};
|
my $hostname = $ENV{HOSTNAME};
|
||||||
|
|
||||||
# tarfile is only available in phase 'backup-end'
|
# tarfile is only available in phase 'backup-end'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user