@@ -81,54 +81,9 @@ install_pgo() {
8181 kubectl get pods -l postgres-operator.crunchydata.com/control-plane=postgres-operator
8282}
8383
84- # Setup Knative for local development
85- setup_knative () {
86- log_info " Setting up Knative for local development..."
8784
88- if kubectl get namespace knative-serving & > /dev/null && kubectl get namespace knative-eventing & > /dev/null; then
89- log_info " Knative already installed, skipping installation"
90- return 0
91- fi
92-
93- log_info " Installing Knative Serving..."
94- kubectl apply -f https://github.com/knative/serving/releases/download/knative-v1.17.0/serving-crds.yaml
95- kubectl apply -f https://github.com/knative/serving/releases/download/knative-v1.17.0/serving-core.yaml
96- kubectl apply -f https://github.com/knative/net-kourier/releases/download/knative-v1.17.0/kourier.yaml
97- # Configure Knative to use Kourier
98- kubectl patch configmap/config-network \
99- --namespace knative-serving \
100- --type merge \
101- --patch ' {"data":{"ingress-class":"kourier.ingress.networking.knative.dev"}}'
102-
103- log_info " Installing Knative Eventing..."
104- # Install Knative Eventing CRDs (includes SinkBinding)
105- kubectl apply -f https://github.com/knative/eventing/releases/download/knative-v1.17.0/eventing-crds.yaml
106- # Install Knative Eventing core components
107- kubectl apply -f https://github.com/knative/eventing/releases/download/knative-v1.17.0/eventing-core.yaml
108-
109- log_info " Waiting for Knative components to be ready..."
110- kubectl wait --for=condition=Ready pod -l app=controller -n knative-serving --timeout=300s
111- kubectl wait --for=condition=Ready pod -l app=webhook -n knative-serving --timeout=300s
112- kubectl wait --for=condition=Ready pod -l app=3scale-kourier-gateway -n kourier-system --timeout=300s
113- kubectl wait --for=condition=Ready pod -l app=eventing-controller -n knative-eventing --timeout=300s
114- kubectl wait --for=condition=Ready pod -l app=eventing-webhook -n knative-eventing --timeout=300s
115-
116- log_info " ✅ Knative installation complete"
117- }
11885
119- deploy_cloudevents_sink () {
120- log_info " Deploying CloudEvents sink for notifications..."
12186
122- kubectl create namespace " $NAMESPACE " --dry-run=client -o yaml | kubectl apply -f -
123-
124- if kubectl apply -f charts/eoapi/samples/cloudevents-sink.yaml; then
125- log_info " Waiting for CloudEvents sink to be ready..."
126- kubectl wait --for=condition=Ready ksvc/eoapi-cloudevents-sink -n " $NAMESPACE " --timeout=300s
127- log_info " ✅ CloudEvents sink deployed successfully"
128- else
129- log_warn " Failed to deploy CloudEvents sink, continuing without it"
130- fi
131- }
13287
13388# Integrated Helm dependency setup
13489setup_helm_dependencies () {
@@ -237,9 +192,7 @@ deploy_eoapi() {
237192 fi
238193 fi
239194
240- if [ " $CI_MODE " != true ]; then
241- deploy_cloudevents_sink
242- fi
195+
243196
244197 # Verify deployment
245198 log_info " Verifying deployment..."
@@ -306,10 +259,6 @@ case $COMMAND in
306259 ;;
307260 deploy)
308261 install_pgo
309-
310- if [ " $CI_MODE " != true ]; then
311- setup_knative
312- fi
313262 setup_helm_dependencies
314263 deploy_eoapi
315264 ;;
0 commit comments