Browse code

extended: fix polling the status of a config that needs to be synced

Michail Kargakis authored on 2016/09/26 23:37:39
Showing 1 changed files
... ...
@@ -297,7 +297,11 @@ func waitForSyncedConfig(oc *exutil.CLI, name string, timeout time.Duration) err
297 297
 	}
298 298
 	generation := dc.Generation
299 299
 	return wait.PollImmediate(200*time.Millisecond, timeout, func() (bool, error) {
300
-		return deployutil.HasSynced(dc, generation), nil
300
+		config, err := oc.REST().DeploymentConfigs(oc.Namespace()).Get(name)
301
+		if err != nil {
302
+			return false, err
303
+		}
304
+		return deployutil.HasSynced(config, generation), nil
301 305
 	})
302 306
 }
303 307