Configuration
This deployment is configured via environment variables (local dev) and Kubernetes Secret/ConfigMap (cluster).
Source of truth
Section titled “Source of truth”- Local:
apps/backend/kubernetes/.env(copy from.env.example) - Kubernetes: created via
apps/backend/kubernetes/scripts/setup-config.sh - API process: additionally requires
DATABASE_URLbecauseflow_like_api::state::Statereads it directly.
Required environment variables
Section titled “Required environment variables”Database
Section titled “Database”DATABASE_URL(required by the API runtime)- Example (local):
postgresql://flowlike:flowlike_dev@localhost:5432/flowlike - Example (cluster):
postgresql://flowlike:flowlike_dev@<postgres-service>:5432/flowlike
- Example (local):
Storage (S3-compatible, required)
Section titled “Storage (S3-compatible, required)”S3_ENDPOINTS3_REGIONS3_ACCESS_KEY_IDS3_SECRET_ACCESS_KEYMETA_BUCKETCONTENT_BUCKETLOG_BUCKET(required for execution logs)
Note: The API accepts both META_BUCKET/CONTENT_BUCKET and META_BUCKET_NAME/CONTENT_BUCKET_NAME for backwards compatibility, but META_BUCKET/CONTENT_BUCKET is the preferred naming convention.
REDIS_URL(defaults toredis://redis:6379inside the cluster)
Kubernetes job dispatching
Section titled “Kubernetes job dispatching”KUBERNETES_NAMESPACE(defaults toflow-like)EXECUTOR_IMAGE(image used for created Jobs)EXECUTOR_RUNTIME_CLASS(defaults tokata)JOB_TIMEOUT_SECONDS(defaults to3600)JOB_MAX_RETRIES(defaults to3)
Logging
Section titled “Logging”RUST_LOG(recommended)
Kubernetes secrets/configmaps
Section titled “Kubernetes secrets/configmaps”The helper script apps/backend/kubernetes/scripts/setup-config.sh creates:
- Secret
flow-like-dbDATABASE_URL
- Secret
flow-like-s3S3_ENDPOINT,S3_REGION,S3_ACCESS_KEY_ID,S3_SECRET_ACCESS_KEYMETA_BUCKET,CONTENT_BUCKET
- Secret
flow-like-redis-secretREDIS_URL
- ConfigMap
flow-like-api-configAPI_HOST,API_PORT,RUST_LOG,METRICS_ENABLED
- ConfigMap
flow-like-executor-configK8S_NAMESPACE,EXECUTOR_IMAGE,USE_KATA_CONTAINERS,JOB_TIMEOUT,MAX_CONCURRENT_JOBS,RUST_LOG
Optional (only if provided):
- Secret
flow-like-openai-secret - Secret
flow-like-sentry-secret
Local development quickstart
Section titled “Local development quickstart”cd apps/backend/kubernetescp .env.example .env# edit .env
docker compose up -dIf you want to mirror secrets/configmaps into a real cluster:
cd apps/backend/kubernetes./scripts/setup-config.sh