policy: allow explicitly selecting NilPolicy
this makes it easier to temporarily disable keel on a resource Signed-off-by: Mate Ory <mate.ory@banzaicloud.com>pull/322/head
parent
2a210558db
commit
7f6851e854
|
@ -92,6 +92,8 @@ func GetPolicy(policyName string, options *Options) Policy {
|
|||
return ParseSemverPolicy(policyName)
|
||||
case "force":
|
||||
return NewForcePolicy(options.MatchTag)
|
||||
case "", "never":
|
||||
return &NilPolicy{}
|
||||
}
|
||||
|
||||
log.Infof("policy.GetPolicy: unknown policy '%s', please check your configuration", policyName)
|
||||
|
|
Loading…
Reference in New Issue