infisical: bring self-hosted stack under GitOps (postgres, valkey, backend); secret.yaml excluded template

This commit is contained in:
2026-07-16 21:47:28 +02:00
parent 1d026f8d57
commit 37737670b5
11 changed files with 248 additions and 30 deletions
@@ -0,0 +1,72 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: infisical-backend
namespace: infisical
spec:
replicas: 1
selector:
matchLabels:
app: infisical-backend
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 0
template:
metadata:
labels:
app: infisical-backend
spec:
# The backend runs DB migrations on startup, so wait for Postgres to be ready.
initContainers:
- name: wait-for-db
image: postgres:14-alpine
command:
- sh
- -c
- "until pg_isready -h infisical-postgres -p 5432 -U $POSTGRES_USER; do echo waiting for db; sleep 2; done"
env:
- name: POSTGRES_USER
valueFrom:
secretKeyRef:
name: infisical-secrets
key: POSTGRES_USER
containers:
- name: backend
image: infisical/infisical:v0.162.6 # pinned — bump deliberately
ports:
- containerPort: 8080
# ENCRYPTION_KEY, AUTH_SECRET, DB_CONNECTION_URI, REDIS_URL (+ POSTGRES_* — ignored) come from the Secret
envFrom:
- secretRef:
name: infisical-secrets
env:
- name: NODE_ENV
value: production
- name: SITE_URL
value: https://infisical.jsme.be
- name: OTEL_TELEMETRY_COLLECTION_ENABLED
value: "false"
# Allow Core to reach the in-cluster Kubernetes API (kubernetes.default.svc,
# a private ClusterIP) for Kubernetes Auth token review. Off by default (SSRF guard).
- name: ALLOW_INTERNAL_IP_CONNECTIONS
value: "true"
readinessProbe:
httpGet:
path: /api/status
port: 8080
initialDelaySeconds: 20
periodSeconds: 10
failureThreshold: 12
livenessProbe:
httpGet:
path: /api/status
port: 8080
initialDelaySeconds: 60
periodSeconds: 20
resources:
requests:
cpu: 250m
memory: 512Mi
limits:
memory: 1Gi
@@ -0,0 +1,14 @@
apiVersion: v1
kind: Service
metadata:
name: infisical-backend
namespace: infisical
labels:
app: infisical-backend
spec:
selector:
app: infisical-backend
ports:
- name: http
port: 8080
targetPort: 8080