Tune PHP-FPM Performance
Auto-detect from server
Run auto-detection (requires server to be configured via
server:add-project):gon tune --autoReads CPU/RAM from the server and writes optimal values to
gon.json.Review the generated config:
cat docker/php-fpm-production.confDeploy to apply:
scp docker/php-fpm-production.conf root@server:/opt/myapp/docker/ssh root@server "cd /opt/myapp && docker compose restart app"
Manual tuning
Edit
gon.jsonperformance section:{"performance": {"pm.max_children": 30,"pm.start_servers": 8}}Regenerate config:
gon tune