Skip to content

Commit 51401b4

Browse files
committed
Adding printer columns to inference model
1 parent 3774251 commit 51401b4

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

api/v1alpha2/inferencemodel_types.go

+4
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ import (
2525
// +kubebuilder:object:root=true
2626
// +kubebuilder:subresource:status
2727
// +kubebuilder:storageversion
28+
// +kubebuilder:printcolumn:name="Model Name", type=string,JSONPath=`.spec.modelName`
29+
// +kubebuilder:printcolumn:name="Inference Pool", type=string,JSONPath=`.spec.poolRef.name`
30+
// +kubebuilder:printcolumn:name="Status", type=string,JSONPath=`.spec.poolRef.name`
31+
// +kubebuilder:printcolumn:name="Age", type=date,JSONPath=`.metadata.creationTimestamp`
2832
// +genclient
2933
type InferenceModel struct {
3034
metav1.TypeMeta `json:",inline"`

config/crd/bases/inference.networking.x-k8s.io_inferencemodels.yaml

+14-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,20 @@ spec:
1414
singular: inferencemodel
1515
scope: Namespaced
1616
versions:
17-
- name: v1alpha2
17+
- additionalPrinterColumns:
18+
- jsonPath: .spec.modelName
19+
name: Model Name
20+
type: string
21+
- jsonPath: .spec.poolRef.name
22+
name: Inference Pool
23+
type: string
24+
- jsonPath: .spec.poolRef.name
25+
name: Status
26+
type: string
27+
- jsonPath: .metadata.creationTimestamp
28+
name: Age
29+
type: date
30+
name: v1alpha2
1831
schema:
1932
openAPIV3Schema:
2033
description: InferenceModel is the Schema for the InferenceModels API.

0 commit comments

Comments
 (0)