Adds Traefik Helm release (kube-system) with ACME HTTP-01 challenge configured for Let's Encrypt, replacing the k3s-disabled bundled Traefik. Migrates all hostnames from *.homelab.local to *.gugagr.xyz and upgrades all ingresses to HTTPS with certresolver=letsencrypt annotations. Adds var.domain (default homelab.local) to Terraform so the domain is a single config point for monitoring and Gitea ingresses. Gateway reads DOMAIN env var at runtime — falls back to homelab.local so local k3d dev continues to work without changes. Co-authored-by: Gonçalo Rodrigues <guga@Goncalos-MacBook-Pro.local> Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
56 lines
1.3 KiB
YAML
56 lines
1.3 KiB
YAML
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
namespace: auth
|
|
name: gateway
|
|
labels:
|
|
app: gateway
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: gateway
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: gateway
|
|
spec:
|
|
imagePullSecrets:
|
|
- name: gitea-registry
|
|
containers:
|
|
- name: gateway
|
|
image: homelab/gateway
|
|
imagePullPolicy: IfNotPresent
|
|
ports:
|
|
- name: http
|
|
containerPort: 8080
|
|
env:
|
|
- name: PORT
|
|
value: "8080"
|
|
- name: LOG_LEVEL
|
|
value: "debug"
|
|
- name: JWT_SECRET
|
|
value: "dev-secret-do-not-use-in-production"
|
|
- name: USERS_SERVICE
|
|
value: "http://users"
|
|
- name: OTEL_EXPORTER_OTLP_ENDPOINT
|
|
value: "jaeger.monitoring.svc:4317"
|
|
- name: DOMAIN
|
|
value: "gugagr.xyz"
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /healthz
|
|
port: http
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /readyz
|
|
port: http
|
|
resources:
|
|
requests:
|
|
cpu: "25m"
|
|
memory: "16Mi"
|
|
limits:
|
|
cpu: "100m"
|
|
memory: "64Mi"
|