mirror of
https://github.com/Traceworks2023/nxtgauge-gitops.git
synced 2026-06-11 05:22:07 +00:00
16 of 20 rust services had no PORT env var set; their main.rs calls
std::env::var('PORT').expect('PORT must be a valid u16') which panicked
on startup. This commit adds env.PORT matching the existing containerPort
for each service. Service ports: gateway=9100 users=9101 companies=9102
jobs=9103 job_seekers=9104 customers=9105 employees=9106 photographers=9107
tutors=9108 makeup_artists=9109 developers=9110 video_editors=9111
graphic_designers=9112 social_media_managers=9113 fitness_trainers=9114
catering_services=9115 payments=9116 ugc_content_creators=9117 leads=9118
61 lines
1.6 KiB
YAML
61 lines
1.6 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: ai-guard
|
|
namespace: nxtgauge-ai
|
|
labels:
|
|
app: ai-guard
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: ai-guard
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: ai-guard
|
|
spec:
|
|
containers:
|
|
- name: ai-guard
|
|
image: registry.nxtgauge.com/ai-guard:latest
|
|
imagePullPolicy: Always
|
|
ports:
|
|
- containerPort: 8080
|
|
name: http
|
|
env:
|
|
- name: RUST_LOG
|
|
value: "info"
|
|
- name: PORT
|
|
value: "8080"
|
|
- name: OLLAMA_BASE_URL
|
|
value: "http://ollama.nxtgauge-ai.svc.cluster.local:11434"
|
|
- name: OLLAMA_CHAT_MODEL
|
|
value: "gemma3:270m"
|
|
- name: LLM_GUARD_URL
|
|
value: "http://llm-guard.nxtgauge-ai.svc.cluster.local:8000"
|
|
- name: PRESIDIO_URL
|
|
value: "http://presidio.nxtgauge-ai.svc.cluster.local:3000"
|
|
- name: AI_SERVICE_KEY
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: ai-guard-secrets
|
|
key: ai-service-key
|
|
resources:
|
|
requests:
|
|
cpu: 100m
|
|
memory: 128Mi
|
|
limits:
|
|
cpu: 1000m
|
|
memory: 512Mi
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /health
|
|
port: 8080
|
|
initialDelaySeconds: 10
|
|
periodSeconds: 20
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /health
|
|
port: 8080
|
|
initialDelaySeconds: 5
|
|
periodSeconds: 10
|