5f1c9adaa6
Removes STREAMABLE session state. No sticky sessions needed. Works across all pods, survives restarts, scales cleanly.
79 lines
2.2 KiB
YAML
79 lines
2.2 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: neuron-mcp-green
|
|
namespace: neuron-prod
|
|
labels:
|
|
app: neuron-mcp
|
|
slot: green
|
|
env: prod
|
|
spec:
|
|
# Scaled to 0 when inactive. Deploy process scales to 1, verifies health, then switches service.
|
|
replicas: 0
|
|
strategy:
|
|
type: Recreate
|
|
selector:
|
|
matchLabels:
|
|
app: neuron-mcp
|
|
slot: green
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: neuron-mcp
|
|
slot: green
|
|
env: prod
|
|
annotations:
|
|
kubectl.kubernetes.io/restartedAt: "2026-04-25T08:10:00Z"
|
|
spec:
|
|
terminationGracePeriodSeconds: 30
|
|
containers:
|
|
- name: neuron-mcp
|
|
# IMAGE UPDATED HERE before scaling to 1
|
|
image: registry.neuralplatform.ai/neuron-technologies/neuron-mcp:1b26e3e
|
|
imagePullPolicy: Always
|
|
ports:
|
|
- name: http
|
|
containerPort: 8080
|
|
env:
|
|
- name: OTEL_EXPORTER_OTLP_ENDPOINT
|
|
value: "http://alloy-otlp.monitoring.svc.cluster.local:4318"
|
|
- name: JAVA_TOOL_OPTIONS
|
|
value: "-XX:+UseContainerSupport -XX:MaxRAMPercentage=75.0 -XX:+ExitOnOutOfMemoryError"
|
|
envFrom:
|
|
- configMapRef:
|
|
name: neuron-prod-config
|
|
- secretRef:
|
|
name: neuron-prod-secrets
|
|
volumeMounts:
|
|
- name: data
|
|
mountPath: /data
|
|
resources:
|
|
requests:
|
|
cpu: 250m
|
|
memory: 512Mi
|
|
limits:
|
|
cpu: 1500m
|
|
memory: 1536Mi
|
|
lifecycle:
|
|
preStop:
|
|
exec:
|
|
command: ["sh", "-c", "sleep 8"]
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /actuator/health/liveness
|
|
port: http
|
|
initialDelaySeconds: 30
|
|
periodSeconds: 30
|
|
failureThreshold: 3
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /actuator/health/readiness
|
|
port: http
|
|
initialDelaySeconds: 10
|
|
periodSeconds: 10
|
|
failureThreshold: 3
|
|
volumes:
|
|
- name: data
|
|
persistentVolumeClaim:
|
|
claimName: neuron-prod-data
|