Skip to content

Commit e7a53af

Browse files
authored
Merge pull request kubernetes-sigs#31 from shaneutt/shaneutt/crd-deployments
Add CRDs deployments
2 parents 8004347 + 9202462 commit e7a53af

File tree

4 files changed

+32
-7
lines changed

4 files changed

+32
-7
lines changed

Makefile

+6-2
Original file line numberDiff line numberDiff line change
@@ -561,7 +561,9 @@ uninstall-k8s: check-kubectl check-kustomize check-envsubst ## Uninstall from Ku
561561
install-openshift-infrastructure:
562562
ifeq ($(strip $(INFRASTRUCTURE_OVERRIDE)),true)
563563
@echo "INFRASTRUCTURE_OVERRIDE is set to true, deploying infrastructure components"
564-
@echo "Installing the Istio Sail Operator and CRDs for Istio and Gateway API"
564+
@echo "Installing CRDs for Gateway API & GIE"
565+
kustomize build deploy/components/crds | kubectl apply --server-side --force-conflicts -f -
566+
@echo "Installing the Istio Sail Operator and CRDs for Istio"
565567
kustomize build --enable-helm deploy/components/sail-operator | kubectl apply --server-side --force-conflicts -f -
566568
@echo "Installing the Istio Control Plane"
567569
kustomize build deploy/components/istio-control-plane | kubectl apply -f -
@@ -586,8 +588,10 @@ ifeq ($(strip $(INFRASTRUCTURE_OVERRIDE)),true)
586588
@echo "INFRASTRUCTURE_OVERRIDE is set to true, removing infrastructure components"
587589
@echo "Uninstalling the Istio Control Plane"
588590
kustomize build deploy/components/istio-control-plane | kubectl delete -f - || true
589-
@echo "Uninstalling the Istio Sail Operator and CRDs for Istio and Gateway API"
591+
@echo "Uninstalling the Istio Sail Operator and CRDs for Istio"
590592
kustomize build --enable-helm deploy/components/sail-operator | kubectl delete -f - || true
593+
@echo "Uninstalling CRDs for Gateway API & GIE"
594+
kustomize build deploy/components/crds | kubectl delete -f - || true
591595
else
592596
$(error "Error: The environment variable INFRASTRUCTURE_OVERRIDE must be set to true in order to run this target.")
593597
endif
+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# ------------------------------------------------------------------------------
2+
# Custom Resource Definitions (CRDs)
3+
#
4+
# This deploys the CRDs needed for development environments (e.g. Gateway API).
5+
#
6+
# **Warning**: CRDs are cluster-level, so in a shared development environment
7+
# this needs to be done in a controlled and communicated manner.
8+
# ------------------------------------------------------------------------------
9+
apiVersion: kustomize.config.k8s.io/v1beta1
10+
kind: Kustomization
11+
12+
resources:
13+
# Gateway API CRDs
14+
- https://github.com/kubernetes-sigs/gateway-api/config/crd?ref=v1.2.1
15+
# Gateway API Inference Extension (GIE) CRDs
16+
# NOTE: deploys whatever is in the current branch
17+
- ../../../config/crd # GIE CRDs

deploy/components/sail-operator/kustomization.yaml

+2-3
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
#
44
# This deploys the Istio Sail Operator via Helm chart to enable the creation
55
# of Istio Control Planes, and ultimately Gateways. This will also deploy all
6-
# the Istio and Gateway API CRDs.
6+
# the Istio CRDs.
77
#
88
# This is required on Kubernetes clusters, and OpenShift clusters versions
9-
# below 4.19 (OpenShift 4.19+ includes all this by default).
9+
# below 4.19, but OpenShift 4.19+ clusters include all this by default.
1010
#
1111
# **Warning**: This needs to be deployed before, and separately from other
1212
# components as it deploys CRDs. It can be deployed with:
@@ -21,7 +21,6 @@ kind: Kustomization
2121
namespace: sail-operator
2222

2323
resources:
24-
- https://github.com/kubernetes-sigs/gateway-api/config/crd?ref=v1.2.1
2524
- namespaces.yaml
2625

2726
helmCharts:

scripts/run-kind.sh

+7-2
Original file line numberDiff line numberDiff line change
@@ -88,20 +88,25 @@ kubectl --context ${KUBE_CONTEXT} -n local-path-storage wait --for=condition=Rea
8888

8989
# Load the vllm simulator image into the cluster
9090
if [ "${CONTAINER_RUNTIME}" == "podman" ]; then
91-
podman tag localhost/vllm-d/vllm-sim:${VLLM_SIMULATOR_VERSION} ${IMAGE_REGISTRY}/vllm-sim:${VLLM_SIMULATOR_VERSION}
9291
podman save ${IMAGE_REGISTRY}/vllm-sim:${VLLM_SIMULATOR_VERSION} -o /dev/stdout | kind --name ${CLUSTER_NAME} load image-archive /dev/stdin
9392
else
9493
kind --name ${CLUSTER_NAME} load docker-image ${IMAGE_REGISTRY}/vllm-sim:${VLLM_SIMULATOR_VERSION}
9594
fi
9695

9796
# Load the ext_proc endpoint-picker image into the cluster
9897
if [ "${CONTAINER_RUNTIME}" == "podman" ]; then
99-
podman tag localhost/${ENDPOINT_PICKER_IMAGE}:${ENDPOINT_PICKER_VERSION} ${IMAGE_REGISTRY}/${ENDPOINT_PICKER_IMAGE}:${ENDPOINT_PICKER_VERSION}
10098
podman save ${IMAGE_REGISTRY}/${ENDPOINT_PICKER_IMAGE}:${ENDPOINT_PICKER_VERSION} -o /dev/stdout | kind --name ${CLUSTER_NAME} load image-archive /dev/stdin
10199
else
102100
kind --name ${CLUSTER_NAME} load docker-image ${IMAGE_REGISTRY}/${ENDPOINT_PICKER_IMAGE}:${ENDPOINT_PICKER_VERSION}
103101
fi
104102

103+
# ------------------------------------------------------------------------------
104+
# CRD Deployment (Gateway API + GIE)
105+
# ------------------------------------------------------------------------------
106+
107+
kubectl kustomize deploy/components/crds |
108+
kubectl --context ${KUBE_CONTEXT} apply --server-side --force-conflicts -f -
109+
105110
# ------------------------------------------------------------------------------
106111
# Sail Operator Deployment
107112
# ------------------------------------------------------------------------------

0 commit comments

Comments
 (0)