Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,42 @@ tests:
reason: "Degraded"
message: ""
lastTransitionTime: "2024-12-01T08:04:21Z"
- name: ocp-release-bundle-4.19.0-x86_64
image: localhost/openshift/release-images@sha256:e98795f7932441b30bb8bcfbbf05912875383fad1f2b3be08a22ec148d68607f
conditions:
- type: Mounted
status: "False"
reason: "Mounted"
message: ""
lastTransitionTime: "2024-12-01T08:04:30Z"
- type: Available
status: "True"
reason: "Available"
message: "Release ocp-release-bundle-4.19.0-x86_64 is currently available on node master-0"
lastTransitionTime: "2024-12-01T08:04:30Z"
- type: Degraded
status: "False"
reason: "Degraded"
message: ""
lastTransitionTime: "2024-12-01T08:04:30Z"
- name: ocp-release-bundle-4.20.0-x86_64
image: localhost.localdomain/openshift/release-images@sha256:f98795f7932441b30bb8bcfbbf05912875383fad1f2b3be08a22ec148d68607f
conditions:
- type: Mounted
status: "False"
reason: "Mounted"
message: ""
lastTransitionTime: "2024-12-01T08:04:40Z"
- type: Available
status: "True"
reason: "Available"
message: "Release ocp-release-bundle-4.20.0-x86_64 is currently available on node master-0"
lastTransitionTime: "2024-12-01T08:04:40Z"
- type: Degraded
status: "False"
reason: "Degraded"
message: ""
lastTransitionTime: "2024-12-01T08:04:40Z"
expected: |
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfigNode
Expand Down Expand Up @@ -84,3 +120,39 @@ tests:
reason: "Degraded"
message: ""
lastTransitionTime: "2024-12-01T08:04:21Z"
- name: ocp-release-bundle-4.19.0-x86_64
image: localhost/openshift/release-images@sha256:e98795f7932441b30bb8bcfbbf05912875383fad1f2b3be08a22ec148d68607f
conditions:
- type: Mounted
status: "False"
reason: "Mounted"
message: ""
lastTransitionTime: "2024-12-01T08:04:30Z"
- type: Available
status: "True"
reason: "Available"
message: "Release ocp-release-bundle-4.19.0-x86_64 is currently available on node master-0"
lastTransitionTime: "2024-12-01T08:04:30Z"
- type: Degraded
status: "False"
reason: "Degraded"
message: ""
lastTransitionTime: "2024-12-01T08:04:30Z"
- name: ocp-release-bundle-4.20.0-x86_64
image: localhost.localdomain/openshift/release-images@sha256:f98795f7932441b30bb8bcfbbf05912875383fad1f2b3be08a22ec148d68607f
conditions:
- type: Mounted
status: "False"
reason: "Mounted"
message: ""
lastTransitionTime: "2024-12-01T08:04:40Z"
- type: Available
status: "True"
reason: "Available"
message: "Release ocp-release-bundle-4.20.0-x86_64 is currently available on node master-0"
lastTransitionTime: "2024-12-01T08:04:40Z"
- type: Degraded
status: "False"
reason: "Degraded"
message: ""
lastTransitionTime: "2024-12-01T08:04:40Z"
4 changes: 3 additions & 1 deletion machineconfiguration/v1/types_machineconfignode.go
Original file line number Diff line number Diff line change
Expand Up @@ -211,12 +211,14 @@ type MachineConfigNodeStatusInternalReleaseImageRef struct {
// image is an OCP release image referenced by digest.
// The format of the image pull spec is: host[:port][/namespace]/name@sha256:<digest>,
// where the digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
// The host must be either exactly "localhost" or a dot-qualified domain name.
// Single-label hosts other than "localhost" are not permitted.
// The length of the whole spec must be between 1 to 447 characters.
// The field is optional, and it will be provided after a release will be successfully installed.
// +kubebuilder:validation:MinLength=1
// +kubebuilder:validation:MaxLength=447
// +kubebuilder:validation:XValidation:rule=`(self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))`,message="the OCI Image reference must end with a valid '@sha256:<digest>' suffix, where '<digest>' is 64 characters long"
// +kubebuilder:validation:XValidation:rule=`(self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))`,message="the OCI Image name should follow the host[:port][/namespace]/name format, resembling a valid URL without the scheme"
// +kubebuilder:validation:XValidation:rule=`(self.split('@')[0].matches('^(localhost|([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+)(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))`,message="the OCI Image name should follow the host[:port][/namespace]/name format, resembling a valid URL without the scheme; host must be either 'localhost' or a dot-qualified domain name"
// +optional
Image string `json:"image,omitempty"`
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,8 @@ spec:
image is an OCP release image referenced by digest.
The format of the image pull spec is: host[:port][/namespace]/name@sha256:<digest>,
where the digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
The host must be either exactly "localhost" or a dot-qualified domain name.
Single-label hosts other than "localhost" are not permitted.
The length of the whole spec must be between 1 to 447 characters.
The field is optional, and it will be provided after a release will be successfully installed.
maxLength: 447
Expand All @@ -460,8 +462,10 @@ spec:
long
rule: (self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))
- message: the OCI Image name should follow the host[:port][/namespace]/name
format, resembling a valid URL without the scheme
rule: (self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
format, resembling a valid URL without the scheme; host
must be either 'localhost' or a dot-qualified domain
name
rule: (self.split('@')[0].matches('^(localhost|([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+)(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
name:
description: |-
name indicates the desired release bundle identifier. This field is required and must be between 1 and 64 characters long.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,8 @@ spec:
image is an OCP release image referenced by digest.
The format of the image pull spec is: host[:port][/namespace]/name@sha256:<digest>,
where the digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
The host must be either exactly "localhost" or a dot-qualified domain name.
Single-label hosts other than "localhost" are not permitted.
The length of the whole spec must be between 1 to 447 characters.
The field is optional, and it will be provided after a release will be successfully installed.
maxLength: 447
Expand All @@ -460,8 +462,10 @@ spec:
long
rule: (self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))
- message: the OCI Image name should follow the host[:port][/namespace]/name
format, resembling a valid URL without the scheme
rule: (self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
format, resembling a valid URL without the scheme; host
must be either 'localhost' or a dot-qualified domain
name
rule: (self.split('@')[0].matches('^(localhost|([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+)(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
name:
description: |-
name indicates the desired release bundle identifier. This field is required and must be between 1 and 64 characters long.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,8 @@ spec:
image is an OCP release image referenced by digest.
The format of the image pull spec is: host[:port][/namespace]/name@sha256:<digest>,
where the digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
The host must be either exactly "localhost" or a dot-qualified domain name.
Single-label hosts other than "localhost" are not permitted.
The length of the whole spec must be between 1 to 447 characters.
The field is optional, and it will be provided after a release will be successfully installed.
maxLength: 447
Expand All @@ -460,8 +462,10 @@ spec:
long
rule: (self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))
- message: the OCI Image name should follow the host[:port][/namespace]/name
format, resembling a valid URL without the scheme
rule: (self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
format, resembling a valid URL without the scheme; host
must be either 'localhost' or a dot-qualified domain
name
rule: (self.split('@')[0].matches('^(localhost|([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+)(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
name:
description: |-
name indicates the desired release bundle identifier. This field is required and must be between 1 and 64 characters long.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,8 @@ spec:
image is an OCP release image referenced by digest.
The format of the image pull spec is: host[:port][/namespace]/name@sha256:<digest>,
where the digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
The host must be either exactly "localhost" or a dot-qualified domain name.
Single-label hosts other than "localhost" are not permitted.
The length of the whole spec must be between 1 to 447 characters.
The field is optional, and it will be provided after a release will be successfully installed.
maxLength: 447
Expand All @@ -460,8 +462,10 @@ spec:
long
rule: (self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))
- message: the OCI Image name should follow the host[:port][/namespace]/name
format, resembling a valid URL without the scheme
rule: (self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
format, resembling a valid URL without the scheme; host
must be either 'localhost' or a dot-qualified domain
name
rule: (self.split('@')[0].matches('^(localhost|([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+)(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
name:
description: |-
name indicates the desired release bundle identifier. This field is required and must be between 1 and 64 characters long.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,8 @@ spec:
image is an OCP release image referenced by digest.
The format of the image pull spec is: host[:port][/namespace]/name@sha256:<digest>,
where the digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
The host must be either exactly "localhost" or a dot-qualified domain name.
Single-label hosts other than "localhost" are not permitted.
The length of the whole spec must be between 1 to 447 characters.
The field is optional, and it will be provided after a release will be successfully installed.
maxLength: 447
Expand All @@ -391,8 +393,10 @@ spec:
long
rule: (self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))
- message: the OCI Image name should follow the host[:port][/namespace]/name
format, resembling a valid URL without the scheme
rule: (self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
format, resembling a valid URL without the scheme; host
must be either 'localhost' or a dot-qualified domain
name
rule: (self.split('@')[0].matches('^(localhost|([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+)(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
name:
description: |-
name indicates the desired release bundle identifier. This field is required and must be between 1 and 64 characters long.
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,8 @@ spec:
image is an OCP release image referenced by digest.
The format of the image pull spec is: host[:port][/namespace]/name@sha256:<digest>,
where the digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
The host must be either exactly "localhost" or a dot-qualified domain name.
Single-label hosts other than "localhost" are not permitted.
The length of the whole spec must be between 1 to 447 characters.
The field is optional, and it will be provided after a release will be successfully installed.
maxLength: 447
Expand All @@ -460,8 +462,10 @@ spec:
long
rule: (self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))
- message: the OCI Image name should follow the host[:port][/namespace]/name
format, resembling a valid URL without the scheme
rule: (self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
format, resembling a valid URL without the scheme; host
must be either 'localhost' or a dot-qualified domain
name
rule: (self.split('@')[0].matches('^(localhost|([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+)(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))
name:
description: |-
name indicates the desired release bundle identifier. This field is required and must be between 1 and 64 characters long.
Expand Down
Loading