Files
archived-gitea-ai-assistant/k8s/gitea-assistant.yaml
jeffusion b92765ce7f chore(deploy): set production LOG_LEVEL to error
Configure production deployments to use LOG_LEVEL=error for minimal log volume.

- Add LOG_LEVEL=error to docker-compose.yml environment

- Add LOG_LEVEL: error to K8s ConfigMap

- Update .env.example with dev/prod LOG_LEVEL guidance

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)
2026-03-26 23:50:59 +08:00

99 lines
2.6 KiB
YAML

---
# ConfigMap: only infrastructure-level env vars that must be known before DB init
apiVersion: v1
kind: ConfigMap
metadata:
name: gitea-assistant-config
namespace: gitea-assistant
labels:
app.kubernetes.io/name: gitea-assistant
app.kubernetes.io/part-of: gitea-assistant
data:
PORT: "5174"
LOG_LEVEL: "error"
# All settings (Gitea connection, webhook secret, admin password, review engine,
# Feishu, memory, etc.) are managed through the Admin Dashboard Web UI.
# They are auto-seeded with secure defaults on first boot.
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: gitea-assistant
namespace: gitea-assistant
labels:
app.kubernetes.io/name: gitea-assistant
app.kubernetes.io/part-of: gitea-assistant
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: gitea-assistant
template:
metadata:
labels:
app.kubernetes.io/name: gitea-assistant
app.kubernetes.io/part-of: gitea-assistant
spec:
containers:
- name: gitea-assistant
image: ghcr.io/jeffusion/gitea-ai-assistant:latest
ports:
- name: http
containerPort: 5174
protocol: TCP
envFrom:
- configMapRef:
name: gitea-assistant-config
- secretRef:
name: gitea-assistant-secret
resources:
limits:
memory: "512Mi"
requests:
memory: "256Mi"
cpu: "100m"
volumeMounts:
- name: data
mountPath: /app/data
livenessProbe:
httpGet:
path: /api/health
port: http
initialDelaySeconds: 10
periodSeconds: 30
timeoutSeconds: 5
failureThreshold: 3
readinessProbe:
httpGet:
path: /api/health
port: http
initialDelaySeconds: 5
periodSeconds: 10
timeoutSeconds: 5
failureThreshold: 3
volumes:
- name: data
hostPath:
# Customize this path to match your node's storage layout
path: /opt/gitea-assistant/data
type: DirectoryOrCreate
---
apiVersion: v1
kind: Service
metadata:
name: gitea-assistant
namespace: gitea-assistant
labels:
app.kubernetes.io/name: gitea-assistant
app.kubernetes.io/part-of: gitea-assistant
spec:
type: ClusterIP
selector:
app.kubernetes.io/name: gitea-assistant
ports:
- name: http
port: 5174
targetPort: http
protocol: TCP