diff --git a/Makefile b/Makefile index 06423ca5d..189eef47d 100644 --- a/Makefile +++ b/Makefile @@ -238,11 +238,15 @@ endif .PHONY: install install: manifests kustomize ## Install CRDs into the K8s cluster specified in ~/.kube/config. + ## Install all CRDs using kubectl create to avoid size limitation problems like for Ray CRDs. + $(KUBECTL) create -k config/crd/ || true ## helm creates objects without aibrix prefix, hence deploying gateway components outside of kustomization + ## This target also handles the KubeRay Operator components included in config/dependency $(KUBECTL) apply -k config/dependency --server-side .PHONY: uninstall uninstall: manifests kustomize ## Uninstall CRDs from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion. + $(KUBECTL) delete --ignore-not-found=$(ignore-not-found) -k config/crd $(KUBECTL) delete --ignore-not-found=$(ignore-not-found) -k config/dependency .PHONY: deploy diff --git a/config/crd/kustomization.yaml b/config/crd/kustomization.yaml index a1483034d..007a5a8bf 100644 --- a/config/crd/kustomization.yaml +++ b/config/crd/kustomization.yaml @@ -5,6 +5,7 @@ resources: - autoscaling - model - orchestration +- ray #+kubebuilder:scaffold:crdkustomizeresource patches: diff --git a/config/crd/ray/kustomization.yaml b/config/crd/ray/kustomization.yaml new file mode 100644 index 000000000..f701f435c --- /dev/null +++ b/config/crd/ray/kustomization.yaml @@ -0,0 +1,4 @@ +resources: +- ray.io_rayclusters.yaml +- ray.io_rayjobs.yaml +- ray.io_rayservices.yaml diff --git a/config/dependency/kuberay-operator/crds/ray.io_rayclusters.yaml b/config/crd/ray/ray.io_rayclusters.yaml similarity index 100% rename from config/dependency/kuberay-operator/crds/ray.io_rayclusters.yaml rename to config/crd/ray/ray.io_rayclusters.yaml diff --git a/config/dependency/kuberay-operator/crds/ray.io_rayjobs.yaml b/config/crd/ray/ray.io_rayjobs.yaml similarity index 100% rename from config/dependency/kuberay-operator/crds/ray.io_rayjobs.yaml rename to config/crd/ray/ray.io_rayjobs.yaml diff --git a/config/dependency/kuberay-operator/crds/ray.io_rayservices.yaml b/config/crd/ray/ray.io_rayservices.yaml similarity index 100% rename from config/dependency/kuberay-operator/crds/ray.io_rayservices.yaml rename to config/crd/ray/ray.io_rayservices.yaml diff --git a/config/default/kustomization.yaml b/config/default/kustomization.yaml index aa90415d1..080edef0b 100644 --- a/config/default/kustomization.yaml +++ b/config/default/kustomization.yaml @@ -19,13 +19,12 @@ namePrefix: aibrix- resources: - ../namespace -- ../crd - ../rbac - ../manager - ../gateway - ../metadata - ../gpu-optimizer -- ../dependency/kuberay-operator +- ../kuberay-operator # [WEBHOOK] To enable webhook, uncomment all the sections with [WEBHOOK] prefix including the one in # crd/kustomization.yaml - ../webhook diff --git a/config/dependency/kustomization.yaml b/config/dependency/kustomization.yaml index 4c9beb746..55b42f011 100644 --- a/config/dependency/kustomization.yaml +++ b/config/dependency/kustomization.yaml @@ -2,6 +2,3 @@ kind: Kustomization resources: - envoy-gateway -- kuberay-operator/crds/ray.io_rayclusters.yaml -- kuberay-operator/crds/ray.io_rayjobs.yaml -- kuberay-operator/crds/ray.io_rayservices.yaml diff --git a/config/dependency/kuberay-operator/README.md b/config/kuberay-operator/README.md similarity index 100% rename from config/dependency/kuberay-operator/README.md rename to config/kuberay-operator/README.md diff --git a/config/dependency/kuberay-operator/kustomization.yaml b/config/kuberay-operator/kustomization.yaml similarity index 100% rename from config/dependency/kuberay-operator/kustomization.yaml rename to config/kuberay-operator/kustomization.yaml diff --git a/config/dependency/kuberay-operator/templates/deployment.yaml b/config/kuberay-operator/templates/deployment.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/deployment.yaml rename to config/kuberay-operator/templates/deployment.yaml diff --git a/config/dependency/kuberay-operator/templates/leader_election_role.yaml b/config/kuberay-operator/templates/leader_election_role.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/leader_election_role.yaml rename to config/kuberay-operator/templates/leader_election_role.yaml diff --git a/config/dependency/kuberay-operator/templates/leader_election_role_binding.yaml b/config/kuberay-operator/templates/leader_election_role_binding.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/leader_election_role_binding.yaml rename to config/kuberay-operator/templates/leader_election_role_binding.yaml diff --git a/config/dependency/kuberay-operator/templates/multiple_namespaces_role.yaml b/config/kuberay-operator/templates/multiple_namespaces_role.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/multiple_namespaces_role.yaml rename to config/kuberay-operator/templates/multiple_namespaces_role.yaml diff --git a/config/dependency/kuberay-operator/templates/multiple_namespaces_rolebinding.yaml b/config/kuberay-operator/templates/multiple_namespaces_rolebinding.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/multiple_namespaces_rolebinding.yaml rename to config/kuberay-operator/templates/multiple_namespaces_rolebinding.yaml diff --git a/config/dependency/kuberay-operator/templates/ray_rayjob_editor_role.yaml b/config/kuberay-operator/templates/ray_rayjob_editor_role.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/ray_rayjob_editor_role.yaml rename to config/kuberay-operator/templates/ray_rayjob_editor_role.yaml diff --git a/config/dependency/kuberay-operator/templates/ray_rayjob_viewer_role.yaml b/config/kuberay-operator/templates/ray_rayjob_viewer_role.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/ray_rayjob_viewer_role.yaml rename to config/kuberay-operator/templates/ray_rayjob_viewer_role.yaml diff --git a/config/dependency/kuberay-operator/templates/ray_rayservice_editor_role.yaml b/config/kuberay-operator/templates/ray_rayservice_editor_role.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/ray_rayservice_editor_role.yaml rename to config/kuberay-operator/templates/ray_rayservice_editor_role.yaml diff --git a/config/dependency/kuberay-operator/templates/ray_rayservice_viewer_role.yaml b/config/kuberay-operator/templates/ray_rayservice_viewer_role.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/ray_rayservice_viewer_role.yaml rename to config/kuberay-operator/templates/ray_rayservice_viewer_role.yaml diff --git a/config/dependency/kuberay-operator/templates/role.yaml b/config/kuberay-operator/templates/role.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/role.yaml rename to config/kuberay-operator/templates/role.yaml diff --git a/config/dependency/kuberay-operator/templates/rolebinding.yaml b/config/kuberay-operator/templates/rolebinding.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/rolebinding.yaml rename to config/kuberay-operator/templates/rolebinding.yaml diff --git a/config/dependency/kuberay-operator/templates/service.yaml b/config/kuberay-operator/templates/service.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/service.yaml rename to config/kuberay-operator/templates/service.yaml diff --git a/config/dependency/kuberay-operator/templates/serviceaccount.yaml b/config/kuberay-operator/templates/serviceaccount.yaml similarity index 100% rename from config/dependency/kuberay-operator/templates/serviceaccount.yaml rename to config/kuberay-operator/templates/serviceaccount.yaml