feat: Setup KIND cluster for local Kubernetes development
- Created 5-node KIND cluster (1 control-plane + 4 workers) - Configured NodePort mappings for console access (30080, 30081) - Created namespace separation (site11-console, site11-pipeline) - Deployed MongoDB and Redis in KIND cluster - Deployed Console backend and frontend with NodePort services - All 4 pods running successfully and verified with browser test Infrastructure: - k8s/kind-dev-cluster.yaml: 5-node cluster configuration - k8s/kind/console-mongodb-redis.yaml: Database deployments - k8s/kind/console-backend.yaml: Backend with NodePort - k8s/kind/console-frontend.yaml: Frontend with NodePort Management Tools: - scripts/kind-setup.sh: Comprehensive cluster management script - docker-compose.kubernetes.yml: Monitoring helper services Documentation: - KUBERNETES.md: Complete usage guide for developers - docs/KIND_SETUP.md: Detailed KIND setup documentation - docs/PROGRESS.md: Updated with KIND cluster completion Console Services Access: - Frontend: http://localhost:3000 (NodePort 30080) - Backend: http://localhost:8000 (NodePort 30081) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
108
k8s/kind/console-mongodb-redis.yaml
Normal file
108
k8s/kind/console-mongodb-redis.yaml
Normal file
@ -0,0 +1,108 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: mongodb
|
||||
namespace: site11-console
|
||||
labels:
|
||||
app: mongodb
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: mongodb
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: mongodb
|
||||
spec:
|
||||
containers:
|
||||
- name: mongodb
|
||||
image: mongo:7.0
|
||||
ports:
|
||||
- containerPort: 27017
|
||||
protocol: TCP
|
||||
env:
|
||||
- name: MONGO_INITDB_DATABASE
|
||||
value: "console_db"
|
||||
resources:
|
||||
requests:
|
||||
memory: "512Mi"
|
||||
cpu: "250m"
|
||||
limits:
|
||||
memory: "1Gi"
|
||||
cpu: "500m"
|
||||
volumeMounts:
|
||||
- name: mongodb-data
|
||||
mountPath: /data/db
|
||||
volumes:
|
||||
- name: mongodb-data
|
||||
emptyDir: {}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: mongodb
|
||||
namespace: site11-console
|
||||
labels:
|
||||
app: mongodb
|
||||
spec:
|
||||
type: ClusterIP
|
||||
selector:
|
||||
app: mongodb
|
||||
ports:
|
||||
- port: 27017
|
||||
targetPort: 27017
|
||||
protocol: TCP
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: redis
|
||||
namespace: site11-console
|
||||
labels:
|
||||
app: redis
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: redis
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: redis
|
||||
spec:
|
||||
containers:
|
||||
- name: redis
|
||||
image: redis:7-alpine
|
||||
ports:
|
||||
- containerPort: 6379
|
||||
protocol: TCP
|
||||
resources:
|
||||
requests:
|
||||
memory: "128Mi"
|
||||
cpu: "100m"
|
||||
limits:
|
||||
memory: "256Mi"
|
||||
cpu: "200m"
|
||||
volumeMounts:
|
||||
- name: redis-data
|
||||
mountPath: /data
|
||||
volumes:
|
||||
- name: redis-data
|
||||
emptyDir: {}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: redis
|
||||
namespace: site11-console
|
||||
labels:
|
||||
app: redis
|
||||
spec:
|
||||
type: ClusterIP
|
||||
selector:
|
||||
app: redis
|
||||
ports:
|
||||
- port: 6379
|
||||
targetPort: 6379
|
||||
protocol: TCP
|
||||
Reference in New Issue
Block a user