From a6a6da5a723dbdb7afa7692c93df5b1fd1326d9d Mon Sep 17 00:00:00 2001 From: Xun Jiang Date: Mon, 26 Feb 2024 10:55:36 +0800 Subject: [PATCH] Modify the label used by the restore CLI to filter the PVR. Signed-off-by: Xun Jiang --- pkg/cmd/cli/restore/describe.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/cmd/cli/restore/describe.go b/pkg/cmd/cli/restore/describe.go index 4bb04b521c..6404ef21d3 100644 --- a/pkg/cmd/cli/restore/describe.go +++ b/pkg/cmd/cli/restore/describe.go @@ -74,7 +74,7 @@ func NewDescribeCommand(f client.Factory, use string) *cobra.Command { podVolumeRestoreList := new(velerov1api.PodVolumeRestoreList) err = kbClient.List(context.TODO(), podVolumeRestoreList, &controllerclient.ListOptions{ Namespace: f.Namespace(), - LabelSelector: labels.SelectorFromSet(map[string]string{velerov1api.BackupNameLabel: label.GetValidName(restore.Name)}), + LabelSelector: labels.SelectorFromSet(map[string]string{velerov1api.RestoreNameLabel: label.GetValidName(restore.Name)}), }) if err != nil { fmt.Fprintf(os.Stderr, "error getting PodVolumeRestores for restore %s: %v\n", restore.Name, err)