Skip to content

Commit

Permalink
s
Browse files Browse the repository at this point in the history
Signed-off-by: kahirokunn <okinakahiro@gmail.com>
  • Loading branch information
kahirokunn committed Dec 16, 2024
1 parent 0bdc1ef commit 3684ca6
Show file tree
Hide file tree
Showing 3 changed files with 129 additions and 87 deletions.
72 changes: 43 additions & 29 deletions artifacts/flagger/crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -526,6 +526,10 @@ spec:
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule: '(size(self.group) == 0 && self.kind == ''Service'')
? has(self.port) : true'
required:
- backendRef
headers:
Expand Down Expand Up @@ -891,7 +895,7 @@ spec:
type: object
additionalProperties:
type: string
backendRef: &backendRef
backend: &backend
type: object
properties:
filters:
Expand Down Expand Up @@ -1006,6 +1010,11 @@ spec:
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule:
"(size(self.group) == 0 && self.kind
== 'Service') ? has(self.port) : true"
required:
- backendRef
type: object
Expand Down Expand Up @@ -1281,35 +1290,40 @@ spec:
self.filter(f, f.type == 'URLRewrite').size()
<= 1
ref:
group:
default: ""
maxLength: 253
pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
default: Service
maxLength: 63
minLength: 1
pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
maxLength: 253
minLength: 1
type: string
namespace:
maxLength: 63
minLength: 1
pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
port:
format: int32
maximum: 65535
minimum: 1
type: integer
type: object
properties:
group:
default: ""
maxLength: 253
pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
default: Service
maxLength: 63
minLength: 1
pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
maxLength: 253
minLength: 1
type: string
namespace:
maxLength: 63
minLength: 1
pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
port:
format: int32
maximum: 65535
minimum: 1
type: integer
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule: '(size(self.group) == 0 && self.kind == ''Service'')
? has(self.port) : true'
canary:
description: Metadata to add to the canary service
type: object
Expand All @@ -1322,7 +1336,7 @@ spec:
type: object
additionalProperties:
type: string
backendRef: *backendRef
backend: *backend
skipAnalysis:
description: Skip analysis and promote canary
type: boolean
Expand Down
72 changes: 43 additions & 29 deletions charts/flagger/crds/crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -526,6 +526,10 @@ spec:
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule: '(size(self.group) == 0 && self.kind == ''Service'')
? has(self.port) : true'
required:
- backendRef
headers:
Expand Down Expand Up @@ -891,7 +895,7 @@ spec:
type: object
additionalProperties:
type: string
backendRef: &backendRef
backend: &backend
type: object
properties:
filters:
Expand Down Expand Up @@ -1006,6 +1010,11 @@ spec:
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule:
"(size(self.group) == 0 && self.kind
== 'Service') ? has(self.port) : true"
required:
- backendRef
type: object
Expand Down Expand Up @@ -1281,35 +1290,40 @@ spec:
self.filter(f, f.type == 'URLRewrite').size()
<= 1
ref:
group:
default: ""
maxLength: 253
pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
default: Service
maxLength: 63
minLength: 1
pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
maxLength: 253
minLength: 1
type: string
namespace:
maxLength: 63
minLength: 1
pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
port:
format: int32
maximum: 65535
minimum: 1
type: integer
type: object
properties:
group:
default: ""
maxLength: 253
pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
default: Service
maxLength: 63
minLength: 1
pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
maxLength: 253
minLength: 1
type: string
namespace:
maxLength: 63
minLength: 1
pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
port:
format: int32
maximum: 65535
minimum: 1
type: integer
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule: '(size(self.group) == 0 && self.kind == ''Service'')
? has(self.port) : true'
canary:
description: Metadata to add to the canary service
type: object
Expand All @@ -1322,7 +1336,7 @@ spec:
type: object
additionalProperties:
type: string
backendRef: *backendRef
backend: *backend
skipAnalysis:
description: Skip analysis and promote canary
type: boolean
Expand Down
72 changes: 43 additions & 29 deletions kustomize/base/flagger/crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -526,6 +526,10 @@ spec:
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule: '(size(self.group) == 0 && self.kind == ''Service'')
? has(self.port) : true'
required:
- backendRef
headers:
Expand Down Expand Up @@ -891,7 +895,7 @@ spec:
type: object
additionalProperties:
type: string
backendRef: &backendRef
backend: &backend
type: object
properties:
filters:
Expand Down Expand Up @@ -1006,6 +1010,11 @@ spec:
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule:
"(size(self.group) == 0 && self.kind
== 'Service') ? has(self.port) : true"
required:
- backendRef
type: object
Expand Down Expand Up @@ -1281,35 +1290,40 @@ spec:
self.filter(f, f.type == 'URLRewrite').size()
<= 1
ref:
group:
default: ""
maxLength: 253
pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
default: Service
maxLength: 63
minLength: 1
pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
maxLength: 253
minLength: 1
type: string
namespace:
maxLength: 63
minLength: 1
pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
port:
format: int32
maximum: 65535
minimum: 1
type: integer
type: object
properties:
group:
default: ""
maxLength: 253
pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
default: Service
maxLength: 63
minLength: 1
pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
maxLength: 253
minLength: 1
type: string
namespace:
maxLength: 63
minLength: 1
pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
port:
format: int32
maximum: 65535
minimum: 1
type: integer
required:
- name
type: object
x-kubernetes-validations:
- message: Must have port for Service reference
rule: '(size(self.group) == 0 && self.kind == ''Service'')
? has(self.port) : true'
canary:
description: Metadata to add to the canary service
type: object
Expand All @@ -1322,7 +1336,7 @@ spec:
type: object
additionalProperties:
type: string
backendRef: *backendRef
backend: *backend
skipAnalysis:
description: Skip analysis and promote canary
type: boolean
Expand Down

0 comments on commit 3684ca6

Please sign in to comment.