- Add liveness probe (restarts pod if unresponsive) - Add readiness probe (removes from service if not ready) - Add resource limits (512Mi-2Gi memory, 250m-1000m CPU) - Update CI to apply full manifest on deploy - Increase frontend rollout timeout to 300s 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
54 lines
1.3 KiB
YAML
54 lines
1.3 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: scraper
|
|
namespace: cannaiq
|
|
labels:
|
|
app: scraper
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: scraper
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: scraper
|
|
spec:
|
|
imagePullSecrets:
|
|
- name: gitea-registry
|
|
containers:
|
|
- name: scraper
|
|
image: registry.spdy.io/cannaiq/backend:latest
|
|
imagePullPolicy: Always
|
|
ports:
|
|
- containerPort: 3000
|
|
envFrom:
|
|
- configMapRef:
|
|
name: cannaiq-config
|
|
# Liveness probe: restarts pod if it becomes unresponsive
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /health
|
|
port: 3000
|
|
initialDelaySeconds: 30
|
|
periodSeconds: 30
|
|
timeoutSeconds: 10
|
|
failureThreshold: 3
|
|
# Readiness probe: removes pod from service if not ready
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /health
|
|
port: 3000
|
|
initialDelaySeconds: 10
|
|
periodSeconds: 10
|
|
timeoutSeconds: 5
|
|
failureThreshold: 3
|
|
resources:
|
|
requests:
|
|
memory: "512Mi"
|
|
cpu: "250m"
|
|
limits:
|
|
memory: "2Gi"
|
|
cpu: "1000m"
|