From c24b11ff8bc6738a8b8d455739ef8d619856d78f Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Tue, 27 Nov 2018 12:16:20 +0200 Subject: [PATCH] Add ProgressDeadlineSeconds to Canary CRD --- pkg/apis/flagger/v1alpha1/types.go | 4 ++++ pkg/apis/flagger/v1alpha1/zz_generated.deepcopy.go | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/pkg/apis/flagger/v1alpha1/types.go b/pkg/apis/flagger/v1alpha1/types.go index 504d5ac1e..5ed75d45b 100755 --- a/pkg/apis/flagger/v1alpha1/types.go +++ b/pkg/apis/flagger/v1alpha1/types.go @@ -48,6 +48,10 @@ type CanarySpec struct { // metrics and thresholds CanaryAnalysis CanaryAnalysis `json:"canaryAnalysis"` + + // the maximum time in seconds for a canary deployment to make progress + // before it is considered to be failed. Defaults to 60s. + ProgressDeadlineSeconds *int32 `json:"progressDeadlineSeconds,omitempty"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object diff --git a/pkg/apis/flagger/v1alpha1/zz_generated.deepcopy.go b/pkg/apis/flagger/v1alpha1/zz_generated.deepcopy.go index cacaa8151..c0361ad46 100644 --- a/pkg/apis/flagger/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/apis/flagger/v1alpha1/zz_generated.deepcopy.go @@ -155,6 +155,11 @@ func (in *CanarySpec) DeepCopyInto(out *CanarySpec) { out.AutoscalerRef = in.AutoscalerRef in.Service.DeepCopyInto(&out.Service) in.CanaryAnalysis.DeepCopyInto(&out.CanaryAnalysis) + if in.ProgressDeadlineSeconds != nil { + in, out := &in.ProgressDeadlineSeconds, &out.ProgressDeadlineSeconds + *out = new(int32) + **out = **in + } return }