fix: bypass /tmp tmpfs for file uploads by redirecting PHP upload_tmp_dir to storage partition

This commit is contained in:
Pontoporeia
2026-07-10 15:42:07 +02:00
parent 1293b1be6c
commit c1a05efcda
5 changed files with 35 additions and 4 deletions
+6
View File
@@ -83,6 +83,12 @@ chown -R www-data:xamxam /var/www/xamxam/storage/cache
chmod -R 2775 /var/www/xamxam/storage/cache
ok "Cache dirs: created and owned by www-data:xamxam"
# Ensure PHP upload temp dir exists on storage partition (not /tmp tmpfs)
mkdir -p /var/www/xamxam/storage/tmp/php-uploads
chown www-data:xamxam /var/www/xamxam/storage/tmp/php-uploads
chmod 2775 /var/www/xamxam/storage/tmp/php-uploads
ok "PHP upload temp dir: /var/www/xamxam/storage/tmp/php-uploads"
# ── Step 2: Nginx config ──────────────────────────────────────────────────────
printf "\n📋 Step 2: Deploying nginx configuration...\n"
echo "--------------------------------------------"