mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Support window nodes for node-shells (#3624)
* Support window nodes for node-shells Signed-off-by: Sebastian Malton <sebastian@malton.name> * Also check beta.kubernetes/os label Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add comment about linux fallback Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
1 parent
c09a57370e
commit
5eb1b8553d
5 files changed
+47
-24
No files matched your search
@@ -236,13 +236,10 @@ export class Node extends KubeObject {
|
||||
}
|
||||
|
||||
getOperatingSystem(): string {
|
||||
const label = this.getLabels().find(label => label.startsWith("kubernetes.io/os="));
|
||||
|
||||
if (label) {
|
||||
return label.split("=", 2)[1];
|
||||
}
|
||||
|
||||
return "linux";
|
||||
return this.metadata?.labels?.["kubernetes.io/os"]
|
||||
|| this.metadata?.labels?.["beta.kubernetes.io/os"]
|
||||
|| this.status?.nodeInfo?.operatingSystem
|
||||
|| "linux";
|
||||
}
|
||||
|
||||
isUnschedulable() {
|
||||
|
||||
Reference in new issue
Block a user