76 lines
1.9 KiB
YAML
76 lines
1.9 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: team-planner-backend
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: team-planner-backend
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: team-planner-backend
|
|
spec:
|
|
imagePullSecrets:
|
|
- name: harbor-creds
|
|
containers:
|
|
- name: team-planner-backend
|
|
image: __BACKEND_IMAGE__
|
|
ports:
|
|
- containerPort: 4001
|
|
env:
|
|
- name: NODE_ENV
|
|
value: "production"
|
|
- name: PORT
|
|
value: "4001"
|
|
- name: DB_HOST
|
|
value: "postgres-service"
|
|
- name: DB_PORT
|
|
value: "5432"
|
|
- name: DB_DATABASE
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: team-planner-secrets
|
|
key: db-name
|
|
- name: DB_USERNAME
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: team-planner-secrets
|
|
key: db-user
|
|
- name: DB_PASSWORD
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: team-planner-secrets
|
|
key: db-password
|
|
- name: KEYCLOAK_REALM_URL
|
|
value: "https://auth.vigdorov.ru/realms/team-planner"
|
|
- name: AI_PROXY_BASE_URL
|
|
value: "http://ai-proxy-service.ai-proxy.svc.cluster.local:3000"
|
|
- name: AI_PROXY_API_KEY
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: team-planner-secrets
|
|
key: ai-proxy-api-key
|
|
- name: NATS_URL
|
|
value: "nats://nats.nats.svc:4222"
|
|
resources:
|
|
requests:
|
|
memory: "256Mi"
|
|
cpu: "250m"
|
|
limits:
|
|
memory: "512Mi"
|
|
cpu: "500m"
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /api/health
|
|
port: 4001
|
|
initialDelaySeconds: 30
|
|
periodSeconds: 10
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /api/health
|
|
port: 4001
|
|
initialDelaySeconds: 10
|
|
periodSeconds: 5
|