homelab/manifests/home-services/ai-gateway.yaml
Nik Afiq fd13b8aedb
Some checks failed
validate / lint (push) Has been cancelled
feat: move Gitea traffic from gitea.nik4nao.com to gitea.home.arpa
The public domain is unreachable while moving, and the cluster had no
Traefik route to Gitea at all (public or internal), leaving every Argo
CD Application stuck in Unknown sync. Add a gitea.home.arpa
Certificate/IngressRoute, repoint Argo CD's repoURL, Gitea's own
DOMAIN/ROOT_URL/SSH_DOMAIN, the container registry references, the
Gitea Actions runner, and the watch-party clone URL at the internal
hostname.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-07 23:06:02 +09:00

90 lines
2.2 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: ai-gateway
namespace: home-services
labels:
app: ai-gateway
spec:
replicas: 1
selector:
matchLabels:
app: ai-gateway
template:
metadata:
labels:
app: ai-gateway
spec:
imagePullSecrets:
- name: gitea-registry-secret
containers:
- name: ai-gateway
image: gitea.home.arpa/nik/ai-gateway:latest
ports:
- containerPort: 50052
name: grpc
env:
- name: GRPC_PORT
value: "50052"
- name: OLLAMA_URL
value: "http://192.168.7.96:11434"
- name: OLLAMA_MODEL
value: "llama3"
- name: OLLAMA_TIMEOUT
value: "120s"
- name: HA_GATEWAY_ADDR
value: "ha-gateway.home-services.svc.cluster.local:50051"
- name: HA_GATEWAY_SERVER_NAME
value: "ha-gateway.home-services.svc.cluster.local"
- name: OTEL_ENDPOINT
value: "otel-collector-opentelemetry-collector.monitoring.svc.cluster.local:4317"
- name: LOG_LEVEL
value: "info"
- name: LOG_FORMAT
value: "json"
- name: LIGHT_CACHE_TTL
value: "60s"
- name: TLS_DIR
value: /tls
readinessProbe:
tcpSocket:
port: 50052
initialDelaySeconds: 5
periodSeconds: 10
livenessProbe:
tcpSocket:
port: 50052
initialDelaySeconds: 10
periodSeconds: 30
resources:
requests:
cpu: 50m
memory: 64Mi
limits:
cpu: 200m
memory: 128Mi
volumeMounts:
- name: tls
mountPath: /tls
readOnly: true
volumes:
- name: tls
secret:
secretName: ai-gateway-tls
---
apiVersion: v1
kind: Service
metadata:
name: ai-gateway
namespace: home-services
labels:
app: ai-gateway
spec:
selector:
app: ai-gateway
ports:
- name: grpc
port: 50052
targetPort: 50052
type: ClusterIP