Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[kots]: add a kernel version check to the preflights #9083

Merged
merged 1 commit into from
Apr 5, 2022
Merged
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
22 changes: 21 additions & 1 deletion install/kots/manifests/kots-preflight.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,16 @@ kind: Preflight
metadata:
name: gitpod
spec:
collectors:
- run:
collectorName: "kernel"
image: alpine/semver
name: kernel
command:
- /bin/sh
- -c
args:
- semver --coerce --range '>=5.4.0' $(uname -r) || echo invalid
analyzers:
- clusterVersion:
outcomes:
Expand All @@ -19,7 +29,17 @@ spec:
uri: https://kubernetes.io
- pass:
message: Your cluster meets the recommended and required versions of Kubernetes.
# @todo(sje): figure out a way of checking the Kernel version is >= 5.4.0-0
- textAnalyze:
checkName: Kernel version is 5.4.0 or above
fileName: kernel/kernel.log
regex: invalid
outcomes:
- pass:
when: "false"
message: Kernel version valid
- fail:
when: "true"
message: Kernel must be 5.4.0 or above
- containerRuntime:
outcomes:
- pass:
Expand Down