deployments/kubernetes/ in the main repository. This guide walks through a production-grade deployment: creating secrets, applying all manifests in order, verifying the rollout, and configuring ingress.
Prerequisites
Before you start, make sure you have:- A Kubernetes 1.24 or later cluster
kubectlconfigured to target the cluster- A Supabase project — see Prerequisites
- A PostgreSQL instance (managed service like RDS, CloudSQL, or Azure Database — or use the in-cluster Postgres manifest)
- Redis (optional — the API degrades gracefully if unavailable)
Manifest directory structure
1
Create the namespace
Apply the namespace manifest to create the
infraudit namespace:2
Create the Secret
Copy the example secret file and fill in your values:Edit Apply the secret:
secret.yaml:3
Apply the ConfigMap
Edit
configmap.yaml to set your FRONTEND_URL, SERVER_PORT, and ENVIRONMENT, then apply:4
Deploy Postgres and Redis
If you’re connecting to an external database, skip the Postgres manifest. Otherwise, deploy both:Wait for both pods to become ready before proceeding:
5
Deploy the API
Apply the API deployment and service:Check the rollout:Verify the health endpoint from inside the cluster:
6
Deploy the frontend
7
Configure ingress
Edit The default ingress configuration assumes an nginx ingress controller and cert-manager for TLS. Adjust the annotations if you use Traefik or another ingress controller.
ingress.yaml to set your hostname and TLS secret, then apply:Default resource limits
The manifests include conservative resource limits. Adjust them based on the number of resources you’re scanning and how frequently you run scans:Horizontal scaling
The API is stateless — sessions are in Supabase and shared cache state is in Redis. You can scale the API horizontally at any time:Next steps
Configuration reference
Review all environment variables and tune your deployment.
Upgrades
Learn how to update image tags and run migrations safely.