perf: optimize Twenty CRM resource usage

- Reduce defaults: 4 CPU/8GB → 2 CPU/4GB (official min is 2GB)
- Node.js heap: 512MB server, 384MB worker (runtime)
- Build-time heap: 3072MB (only during compilation)
- PG pool: reduce to 5 connections
- PostgreSQL: tune shared_buffers/work_mem/effective_cache_size
- Redis: cap at 64MB with noeviction policy
- Unset NODE_OPTIONS after build to not leak into runtime
This commit is contained in:
MickLesk
2026-02-22 14:48:11 +01:00
parent 5ab302102b
commit fe48d08c69
3 changed files with 28 additions and 6 deletions

View File

@@ -19,8 +19,8 @@
"type": "default",
"script": "ct/twenty.sh",
"resources": {
"cpu": 4,
"ram": 8192,
"cpu": 2,
"ram": 4096,
"hdd": 20,
"os": "Debian",
"version": "13"