Detect rancher desktop (#3711)

This commit is contained in:
Lauri Nevala authored and GitHub committed 2021-09-01 16:32:10 +03:00
1 parent edee99a031
commit c0398effc5
1 file changed
+8
@@ -33,6 +33,10 @@ export class DistributionDetector extends BaseClusterDetector {
return { value: "rke", accuracy: 80};
}
if (this.isRancherDesktop()) {
return { value: "rancher-desktop", accuracy: 80};
}
if (this.isK3s()) {
return { value: "k3s", accuracy: 80};
}
@@ -172,6 +176,10 @@ export class DistributionDetector extends BaseClusterDetector {
return this.version.includes("-rancher");
}
protected isRancherDesktop() {
return this.cluster.contextName === "rancher-desktop";
}
protected isK3s() {
return this.version.includes("+k3s");
}