Skip to content

Commit

Permalink
KEP-2170: Generate CRD manifests for v2 CustomResources (#2237)
Browse files Browse the repository at this point in the history
* KEP-2170: Generate CRDs for v2 CRDs

Signed-off-by: Yuki Iwai <[email protected]>

* Replace v2alpha with v2

Signed-off-by: Yuki Iwai <[email protected]>

---------

Signed-off-by: Yuki Iwai <[email protected]>
  • Loading branch information
tenzen-y authored Aug 30, 2024
1 parent 13c3ee8 commit 2455f7d
Show file tree
Hide file tree
Showing 7 changed files with 21,652 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ manifests: controller-gen ## Generate WebhookConfiguration, ClusterRole and Cust
output:crd:artifacts:config=manifests/base/crds \
output:rbac:artifacts:config=manifests/base/rbac \
output:webhook:artifacts:config=manifests/base/webhook
$(CONTROLLER_GEN) "crd:generateEmbeddedObjectMeta=true" paths="./pkg/apis/kubeflow.org/v2alpha1/..." \
output:crd:artifacts:config=manifests/v2/base/crds

generate: controller-gen ## Generate apidoc, sdk and code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
$(CONTROLLER_GEN) object:headerFile="hack/boilerplate/boilerplate.go.txt" paths="./pkg/apis/..."
Expand Down
9,275 changes: 9,275 additions & 0 deletions manifests/v2/base/crds/kubeflow.org_clustertrainingruntimes.yaml

Large diffs are not rendered by default.

9,275 changes: 9,275 additions & 0 deletions manifests/v2/base/crds/kubeflow.org_trainingruntimes.yaml

Large diffs are not rendered by default.

3,090 changes: 3,090 additions & 0 deletions manifests/v2/base/crds/kubeflow.org_trainjobs.yaml

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions manifests/v2/base/crds/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- kubeflow.org_clustertrainingruntimes.yaml
- kubeflow.org_trainingruntimes.yaml
- kubeflow.org_trainjobs.yaml
3 changes: 3 additions & 0 deletions pkg/apis/kubeflow.org/v2alpha1/trainingruntime_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ import (
)

// +kubebuilder:object:root=true
// +kubebuilder:storageversion
// +kubebuilder:resource:scope=Cluster

// ClusterTrainingRuntime represents a training runtime which can be referenced as part of
// `trainingRuntimeRef` API in TrainJob. This resource is a cluster-scoped and can be referenced
Expand Down Expand Up @@ -51,6 +53,7 @@ type ClusterTrainingRuntimeList struct {
}

// +kubebuilder:object:root=true
// +kubebuilder:storageversion

// TrainingRuntime represents a training runtime which can be referenced as part of
// `trainingRuntimeRef` API in TrainJob. This resource is a namespaced-scoped and can be referenced
Expand Down
1 change: 1 addition & 0 deletions pkg/apis/kubeflow.org/v2alpha1/trainjob_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import (

// +kubebuilder:object:root=true
// +kubebuilder:subresource:status
// +kubebuilder:storageversion
// +kubebuilder:printcolumn:name="State",type=string,JSONPath=`.status.conditions[-1:].type`
// +kubebuilder:printcolumn:name="Age",type=date,JSONPath=`.metadata.creationTimestamp`

Expand Down

0 comments on commit 2455f7d

Please sign in to comment.