Commit d867cbfa authored by Lang Martin's avatar Lang Martin
Browse files

structs validate requires Canary for AutoPromote

parent 2772cc26
Showing with 3 additions and 0 deletions
+3 -0
......@@ -3880,6 +3880,9 @@ func (u *UpdateStrategy) Validate() error {
if u.Canary < 0 {
multierror.Append(&mErr, fmt.Errorf("Canary count can not be less than zero: %d < 0", u.Canary))
}
if u.Canary == 0 && u.AutoPromote {
multierror.Append(&mErr, fmt.Errorf("Auto Promote requires a Canary count greater than zero"))
}
if u.MinHealthyTime < 0 {
multierror.Append(&mErr, fmt.Errorf("Minimum healthy time may not be less than zero: %v", u.MinHealthyTime))
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment