server { listen 80; root /app/public; index index.html; location / { try_files $uri /index.html /index.php$is_args$args; } location ~ \.php$ { fastcgi_pass api:9000; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } }