Skip to content

Commit e207638

Browse files
committed
Remove canary from the possible options for deployment strategies
1 parent 801dc60 commit e207638

File tree

3 files changed

+7
-9
lines changed

3 files changed

+7
-9
lines changed

CHANGES.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## v5.1.0 (unreleased)
22

3-
* Add `--deployment-strategy` which can have the value `rolling`, `canary`, `blue-green` or `immediate` to service.
3+
* Add `--deployment-strategy` which can have the value `rolling`, `blue-green` or `immediate` to service.
44
- https://github.com/koyeb/koyeb-cli/pull/248/files
55

66
## v5.0.0 (2024-08-20)

docs/reference.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ See examples of koyeb service create --help
283283
--checks-grace-period strings Set healthcheck grace period in seconds.
284284
Use the format <healthcheck>=<seconds>, for example --checks-grace-period 8080=10
285285
286-
--deployment-strategy STRATEGY Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
286+
--deployment-strategy string Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
287287
--docker string Docker image
288288
--docker-args strings Set arguments to the docker command. To provide multiple arguments, use the --docker-args flag multiple times.
289289
--docker-command string Set the docker CMD explicitly. To provide arguments to the command, use the --docker-args flag.
@@ -575,7 +575,7 @@ koyeb deploy <path> <app>/<service> [flags]
575575
--checks-grace-period strings Set healthcheck grace period in seconds.
576576
Use the format <healthcheck>=<seconds>, for example --checks-grace-period 8080=10
577577
578-
--deployment-strategy STRATEGY Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
578+
--deployment-strategy string Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
579579
--env strings Update service environment variables using the format KEY=VALUE, for example --env FOO=bar
580580
To use the value of a secret as an environment variable, specify the secret name preceded by @, for example --env FOO=@bar
581581
To delete an environment variable, prefix its name with '!', for example --env '!FOO'
@@ -1375,7 +1375,7 @@ $> koyeb service create myservice --app myapp --docker nginx --port 80:tcp
13751375
--checks-grace-period strings Set healthcheck grace period in seconds.
13761376
Use the format <healthcheck>=<seconds>, for example --checks-grace-period 8080=10
13771377
1378-
--deployment-strategy STRATEGY Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
1378+
--deployment-strategy string Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
13791379
--docker string Docker image
13801380
--docker-args strings Set arguments to the docker command. To provide multiple arguments, use the --docker-args flag multiple times.
13811381
--docker-command string Set the docker CMD explicitly. To provide arguments to the command, use the --docker-args flag.
@@ -1795,7 +1795,7 @@ $> koyeb service update myapp/myservice --port 80:tcp --route '!/'
17951795
--checks-grace-period strings Set healthcheck grace period in seconds.
17961796
Use the format <healthcheck>=<seconds>, for example --checks-grace-period 8080=10
17971797
1798-
--deployment-strategy STRATEGY Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
1798+
--deployment-strategy string Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".
17991799
--docker string Docker image
18001800
--docker-args strings Set arguments to the docker command. To provide multiple arguments, use the --docker-args flag multiple times.
18011801
--docker-command string Set the docker CMD explicitly. To provide arguments to the command, use the --docker-args flag.

pkg/koyeb/services.go

+2-4
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ func (h *ServiceHandler) addServiceDefinitionFlagsForAllSources(flags *pflag.Fla
320320
flags.String("instance-type", "nano", "Instance type")
321321

322322
var strategy DeploymentStrategy
323-
flags.Var(&strategy, "deployment-strategy", `Deployment strategy, either "rolling" (default), "canary", "blue-green" or "immediate".`)
323+
flags.Var(&strategy, "deployment-strategy", `Deployment strategy, either "rolling" (default), "blue-green" or "immediate".`)
324324

325325
flags.Int64("scale", 1, "Set both min-scale and max-scale")
326326
flags.Int64("min-scale", 1, "Min scale")
@@ -1736,14 +1736,12 @@ func (s *DeploymentStrategy) Set(value string) error {
17361736
switch value {
17371737
case "rolling":
17381738
*s = DeploymentStrategy(koyeb.DEPLOYMENTSTRATEGYTYPE_ROLLING)
1739-
case "canary":
1740-
*s = DeploymentStrategy(koyeb.DEPLOYMENTSTRATEGYTYPE_CANARY)
17411739
case "blue-green":
17421740
*s = DeploymentStrategy(koyeb.DEPLOYMENTSTRATEGYTYPE_BLUE_GREEN)
17431741
case "immediate":
17441742
*s = DeploymentStrategy(koyeb.DEPLOYMENTSTRATEGYTYPE_IMMEDIATE)
17451743
default:
1746-
return fmt.Errorf("invalid deployment strategy: %s. Valid values are: rolling, canary, blue-green, immediate.", value)
1744+
return fmt.Errorf("invalid deployment strategy: %s. Valid values are: rolling, blue-green, immediate.", value)
17471745
}
17481746
return nil
17491747
}

0 commit comments

Comments
 (0)