mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
29 lines
634 B
TypeScript
29 lines
634 B
TypeScript
/**
|
|
* Copyright (c) OpenLens Authors. All rights reserved.
|
|
* Licensed under MIT License. See LICENSE in root directory for more information.
|
|
*/
|
|
|
|
import { KubeObject } from "../kube-object";
|
|
|
|
export interface ComponentStatusCondition {
|
|
type: string;
|
|
status: string;
|
|
message: string;
|
|
}
|
|
|
|
export interface ComponentStatus {
|
|
conditions: ComponentStatusCondition[];
|
|
}
|
|
|
|
export class ComponentStatus extends KubeObject {
|
|
static kind = "ComponentStatus";
|
|
|
|
static namespaced = false;
|
|
|
|
static apiBase = "/api/v1/componentstatuses";
|
|
|
|
getTruthyConditions() {
|
|
return this.conditions.filter((c) => c.status === "True");
|
|
}
|
|
}
|