From a5b373da2647a2b90f5ea324bfddc64e4f34f16f Mon Sep 17 00:00:00 2001 From: "A. F. Dudley" Date: Sat, 24 Jan 2026 16:39:11 -0500 Subject: [PATCH] Check for None before creating k8s service get_service() returns None when there are no http-proxy routes, so we must check before calling create_namespaced_service(). Co-Authored-By: Claude Opus 4.5 --- stack_orchestrator/deploy/k8s/deploy_k8s.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stack_orchestrator/deploy/k8s/deploy_k8s.py b/stack_orchestrator/deploy/k8s/deploy_k8s.py index cf8f564f..3d0b697c 100644 --- a/stack_orchestrator/deploy/k8s/deploy_k8s.py +++ b/stack_orchestrator/deploy/k8s/deploy_k8s.py @@ -241,7 +241,7 @@ class K8sDeployer(Deployer): service = self.cluster_info.get_service() if opts.o.debug: print(f"Sending this service: {service}") - if not opts.o.dry_run: + if service and not opts.o.dry_run: service_resp = self.core_api.create_namespaced_service( namespace=self.k8s_namespace, body=service )