Commit ffe9f69
feat: add OpenShift deployment infrastructure with GPU support
This commit adds comprehensive OpenShift deployment support with GPU-enabled
specialist model containers, providing a complete automation solution for
deploying the semantic router to OpenShift clusters.
## New Files (deploy/openshift/):
**Core Deployment:**
- deployment.yaml: Kubernetes deployment manifest with GPU support
* 4-container pod: semantic-router, model-a, model-b, envoy-proxy
* CDI annotations for GPU device injection (gpu=0, gpu=1)
* GPU node selection and tolerations
* PVC mounts for models and cache
* Production log levels (INFO for containers, info for Envoy)
- deploy-to-openshift.sh: Main deployment automation script (826 lines)
* Auto-detection of OpenShift server and existing login
* Enhanced deployment method with llm-katan specialists
* Alternative methods: kustomize, template
* Configurable resources, storage, logging
* Automatic namespace creation
* Inline Dockerfile build for llm-katan image
* Service and route creation
* Optional port forwarding (disabled by default)
* Displays OpenWebUI endpoint at completion
- cleanup-openshift.sh: Cleanup automation script (494 lines)
* Auto-detection of cluster and namespace
* Graceful cleanup with confirmation
* Port forwarding cleanup
* Comprehensive resource deletion
**Configuration:**
- config-openshift.yaml: Semantic router config for OpenShift
* Math-specialist and coding-specialist endpoints
* Category-to-specialist routing
* PII and jailbreak detection configuration
- envoy-openshift.yaml: Envoy proxy configuration
* HTTP listener on port 8801
* External processing filter
* Specialist model routing
* /v1/models aggregation
**Container Image:**
- Dockerfile.llm-katan: GPU-enabled specialist container image
* Python 3.10-slim base
* PyTorch with CUDA 12.1 support
* llm-katan, transformers, accelerate packages
* HuggingFace caching configuration
* Health check endpoint
**Alternative Deployment Methods:**
- kustomization.yaml: Kustomize deployment option
- template.yaml: OpenShift template with parameters
**Documentation & Validation:**
- README.md: Comprehensive deployment documentation
- validate-deployment.sh: 12-test validation script
* Namespace, deployment, container readiness
* GPU detection in both specialist containers
* Model loading verification
* PVC, service, route checks
* GPU node scheduling confirmation
## Integration Files:
- Makefile: Add include for tools/make/openshift.mk
- tools/make/openshift.mk: Optional make targets for OpenShift operations
* openshift-deploy, openshift-cleanup, openshift-status
* openshift-logs, openshift-routes, openshift-test
* Port forwarding helpers
## Key Features:
1. **GPU Support**: Full NVIDIA GPU support via CDI device injection
2. **Specialist Models**: Real llm-katan containers for math/coding tasks
3. **Zero-Touch Deployment**: Auto-detection of cluster, automatic builds
4. **Production Ready**: Production log levels, proper health checks
5. **Validation**: Comprehensive 12-test validation suite
6. **UX Enhancements**: OpenWebUI endpoint display, optional port forwarding
7. **Clean Separation**: Only touches deploy/openshift/ (plus minimal Makefile)
## Architecture:
```
Pod: semantic-router
├── semantic-router (main ExtProc service, port 50051)
├── model-a (llm-katan math specialist, port 8000, GPU 0)
├── model-b (llm-katan coding specialist, port 8001, GPU 1)
└── envoy-proxy (gateway, port 8801)
```
## Testing:
Validated on OpenShift with NVIDIA L4 GPUs:
- All 4 containers running
- GPUs detected in both specialist containers
- Models loaded on CUDA
- PVCs bound
- Services and routes accessible
- Streaming functionality working
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
Signed-off-by: Yossi Ovadia <[email protected]>1 parent 959e649 commit ffe9f69
File tree
12 files changed
+3115
-0
lines changed- deploy/openshift
- tools/make
12 files changed
+3115
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
0 commit comments