Ver código fonte

check for other forms of the deployment name

Alexander Belanger 4 anos atrás
pai
commit
50e4f2f071
1 arquivos alterados com 1 adições e 1 exclusões
  1. 1 1
      cli/cmd/bluegreen.go

+ 1 - 1
cli/cmd/bluegreen.go

@@ -120,7 +120,7 @@ func bluegreenSwitch(_ *types.GetAuthenticatedUserResponse, client *api.Client,
 
 		// get the deployment which matches the new image tag
 		for _, depl := range depls.Items {
-			if depl.ObjectMeta.Name == fmt.Sprintf("%s-web-%s", app, tag) {
+			if depl.ObjectMeta.Name == fmt.Sprintf("%s-web-%s", app, tag) || depl.ObjectMeta.Name == fmt.Sprintf("%s-%s", app, tag) {
 				foundDeployment = true
 
 				// determine if the deployment has an appropriate number of ready replicas