server {
    listen 80;
    server_name _;
    root /var/www/html/public;
    index index.php;
    client_max_body_size 1m;
    add_header X-Content-Type-Options nosniff always;
    location / { try_files $uri $uri/ /index.php?$query_string; }
    location ~ ^/index\.php$ {
        include fastcgi_params;
        fastcgi_pass app:9000;
        fastcgi_param SCRIPT_FILENAME /var/www/html/public/index.php;
        fastcgi_param HTTP_X_FORWARDED_PROTO $http_x_forwarded_proto;
        fastcgi_hide_header X-Powered-By;
        fastcgi_read_timeout 30;
    }
    location ~ \.(php|env|log)$ { deny all; }
    location ~ /\. { deny all; }
    location /build/ { expires 1y; add_header Cache-Control "public, immutable"; }
}
