f3679e6176
Introduce a self-contained kustomize stack under deploy/k3s covering namespace, config, placeholder secrets, infra StatefulSets, app Deployments/Services, migration and minio-init Jobs, and Traefik Ingress for both tenant and ops hosts. Add Dockerfile.ops-web so the operations frontend can ship as an nginx image, and extend the offline package script to build and bundle ops-api, kol-assist-worker, and ops-web alongside the k3s manifests. Wire the new ops/security knobs through .env.example and the compose stack. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
81 lines
2.1 KiB
YAML
81 lines
2.1 KiB
YAML
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: monitoring-postgres
|
|
labels:
|
|
app.kubernetes.io/name: monitoring-postgres
|
|
spec:
|
|
selector:
|
|
app.kubernetes.io/name: monitoring-postgres
|
|
ports:
|
|
- name: postgres
|
|
port: 5432
|
|
targetPort: postgres
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: StatefulSet
|
|
metadata:
|
|
name: monitoring-postgres
|
|
labels:
|
|
app.kubernetes.io/name: monitoring-postgres
|
|
spec:
|
|
serviceName: monitoring-postgres
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app.kubernetes.io/name: monitoring-postgres
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app.kubernetes.io/name: monitoring-postgres
|
|
spec:
|
|
containers:
|
|
- name: postgres
|
|
image: postgres:16-alpine
|
|
imagePullPolicy: IfNotPresent
|
|
ports:
|
|
- name: postgres
|
|
containerPort: 5432
|
|
env:
|
|
- name: POSTGRES_DB
|
|
value: geo_monitoring
|
|
- name: POSTGRES_USER
|
|
value: geo
|
|
- name: POSTGRES_PASSWORD
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: geo-rankly-app-secret
|
|
key: POSTGRES_PASSWORD
|
|
- name: PGDATA
|
|
value: /var/lib/postgresql/data/pgdata
|
|
readinessProbe:
|
|
exec:
|
|
command: ["pg_isready", "-U", "geo", "-d", "geo_monitoring"]
|
|
initialDelaySeconds: 5
|
|
periodSeconds: 5
|
|
timeoutSeconds: 5
|
|
livenessProbe:
|
|
exec:
|
|
command: ["pg_isready", "-U", "geo", "-d", "geo_monitoring"]
|
|
initialDelaySeconds: 30
|
|
periodSeconds: 10
|
|
timeoutSeconds: 5
|
|
resources:
|
|
requests:
|
|
cpu: 100m
|
|
memory: 256Mi
|
|
limits:
|
|
cpu: "1"
|
|
memory: 1Gi
|
|
volumeMounts:
|
|
- name: monitoring-pgdata
|
|
mountPath: /var/lib/postgresql/data
|
|
volumeClaimTemplates:
|
|
- metadata:
|
|
name: monitoring-pgdata
|
|
spec:
|
|
accessModes: ["ReadWriteOnce"]
|
|
resources:
|
|
requests:
|
|
storage: 20Gi
|