mirror of
https://github.com/vmware-tanzu/velero.git
synced 2026-08-15 11:46:06 +00:00
+4
-1
@@ -310,7 +310,7 @@ func waitVeleroReady(ctx context.Context, namespace string, useRestic bool) erro
|
||||
|
||||
if useRestic {
|
||||
fmt.Println("Waiting for Velero restic daemonset to be ready.")
|
||||
wait.PollImmediate(5*time.Second, 1*time.Minute, func() (bool, error) {
|
||||
err := wait.PollImmediate(5*time.Second, 1*time.Minute, func() (bool, error) {
|
||||
stdout, stderr, err := velerexec.RunCommand(exec.CommandContext(ctx, "kubectl", "get", "daemonset/restic",
|
||||
"-o", "json", "-n", namespace))
|
||||
if err != nil {
|
||||
@@ -325,6 +325,9 @@ func waitVeleroReady(ctx context.Context, namespace string, useRestic bool) erro
|
||||
}
|
||||
return false, nil
|
||||
})
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "fail to wait for the velero restic ready")
|
||||
}
|
||||
}
|
||||
|
||||
fmt.Printf("Velero is installed and ready to be tested in the %s namespace! ⛵ \n", namespace)
|
||||
|
||||
@@ -46,8 +46,10 @@ func getProviderPlugins(providerName string) []string {
|
||||
return []string{"velero/velero-plugin-for-microsoft-azure:v1.2.0"}
|
||||
case "vsphere":
|
||||
return []string{"velero/velero-plugin-for-aws:v1.2.1", "vsphereveleroplugin/velero-plugin-for-vsphere:v1.1.1"}
|
||||
case "gcp":
|
||||
return []string{"velero/velero-plugin-for-gcp:v1.2.1"}
|
||||
default:
|
||||
return []string{""}
|
||||
panic(fmt.Errorf("unknown provider name: %s", providerName))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user