Technology Compatibility Kit for ConfigHub + Kubernetes Integration
This minimal test verifies that ConfigHub and Kubernetes are working together correctly. It's designed to be:
- ✅ Simple - No dependencies on any specific project
- ✅ Fast - Completes in < 2 minutes
- ✅ Thorough - Tests the complete ConfigHub → Kubernetes flow
- ✅ Self-cleaning - All resources automatically cleaned up
- ConfigHub API connectivity - Can authenticate and create spaces/units
- Kubernetes cluster access - Can create Kind cluster and deploy pods
- Worker installation - Can install and connect ConfigHub worker
- Apply workflow - Can apply ConfigHub units to Kubernetes
- Live state verification - ConfigHub can read Kubernetes state
curl -fsSL https://raw.githubusercontent.com/monadic/devops-sdk/main/test-confighub-k8s | bashcd /path/to/devops-sdk
./test-confighub-k8sBoth traderx and microtraderx include wrapper scripts:
# In traderx or microtraderx
./test-confighub-k8scub- ConfigHub CLI (install)kind- Kubernetes in Docker (install)kubectl- Kubernetes CLI (install)- ConfigHub authentication:
cub auth login
The test creates minimal resources:
| Resource | Name | Purpose |
|---|---|---|
| Kind cluster | confighub-tck |
Kubernetes test environment |
| ConfigHub space | confighub-tck |
Configuration namespace |
| ConfigHub unit | test-pod |
Nginx pod configuration |
| Worker | tck-worker |
ConfigHub → Kubernetes bridge |
| Kubernetes pod | test-pod |
Running nginx container |
All resources are automatically deleted on exit (success or failure).
🧪 ConfigHub + Kubernetes Mini TCK
===================================
This test verifies:
- ConfigHub API connectivity
- Kubernetes cluster access
- Worker installation
- Unit apply workflow
- Live state verification
Checking prerequisites...
✅ All prerequisites met
Step 1: Create Kind cluster
----------------------------
✅ Kind cluster created
Step 2: Create ConfigHub space
-------------------------------
✅ ConfigHub space created
Step 3: Create test unit (nginx pod)
-------------------------------------
✅ Unit created in ConfigHub
Step 4: Install ConfigHub worker
---------------------------------
✅ Worker installed and connected
Step 5: Apply unit to Kubernetes
---------------------------------
✅ Unit applied
Step 6: Verify deployment
-------------------------
Waiting for pod to be ready (max 60s)...
✅ Pod is ready in Kubernetes
Step 7: Verify ConfigHub live state
------------------------------------
✅ ConfigHub live state shows: Running
Step 8: Final verification
--------------------------
✅ Pod verified in Kubernetes: Running
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🎉 SUCCESS! ConfigHub + Kubernetes integration verified
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Summary:
✅ Kind cluster: confighub-tck
✅ ConfigHub space: confighub-tck
✅ ConfigHub unit: test-pod
✅ Worker: tck-worker (connected)
✅ Pod status: Running
✅ ConfigHub → Kubernetes flow: WORKING
Your ConfigHub + Kubernetes environment is correctly configured!
Note: All test resources will be cleaned up automatically.
🧹 Cleaning up test resources...
✅ Cleanup complete
brew install confighubai/tap/cubcub auth loginbrew install kindCheck Docker is running:
docker psCheck Kind cluster health:
kubectl cluster-info --context kind-confighub-tckAdd to prerequisites section:
### Pre-Flight Check
./test-confighub-k8sAdd to README:
## Prerequisites
Before deploying, verify your environment:
./test-confighub-k8s- Zero project dependencies - Works standalone, no imports from traderx/microtraderx
- Minimal resources - 1 cluster, 1 space, 1 unit, 1 worker, 1 pod
- Fast execution - Complete in < 2 minutes
- Clean exit - Always cleanup, even on failure
- Clear output - Step-by-step progress with emojis
- Verifiable - Tests both ConfigHub API and Kubernetes state
0- Success, all tests passed1- Failure, check output for details
- Pre-flight check - Before starting tutorials
- CI/CD validation - Verify test environment
- Debugging - Isolate ConfigHub vs Kubernetes issues
- Documentation validation - Verify documented commands work
- Onboarding - New user environment validation
Run BEFORE committing documentation with cub commands:
# 1. Verify environment works
./test-confighub-k8s
# 2. Validate all cub commands in docs
curl -fsSL https://raw.githubusercontent.com/monadic/devops-sdk/main/cub-command-analyzer.sh | bash -s -- .Why: Example commands in README/QUICKSTART files are copy-pasted by users. Invalid examples cause hours of debugging frustration and erode trust in documentation.