mirror of
https://codeberg.org/demostf/api.git
synced 2026-06-03 18:04:08 +02:00
31 lines
677 B
Text
31 lines
677 B
Text
server {
|
|
listen 80;
|
|
server_name localhost;
|
|
root /usr/share/nginx/html;
|
|
|
|
client_max_body_size 200m;
|
|
|
|
if ($request_method = POST ) {
|
|
rewrite /upload /do_upload last;
|
|
break;
|
|
}
|
|
|
|
location /do_upload {
|
|
fastcgi_pass api:9000;
|
|
fastcgi_index index.php;
|
|
include fastcgi_params;
|
|
fastcgi_param SCRIPT_FILENAME /app/src/public/upload.php;
|
|
}
|
|
|
|
index index.php;
|
|
|
|
try_files $uri /index.php?$query_string /index.php;
|
|
|
|
location ~ ^(.+?\.php)(/.*)?$ {
|
|
fastcgi_param PATH_INFO $2;
|
|
fastcgi_pass api:9000;
|
|
fastcgi_index index.php;
|
|
fastcgi_param SCRIPT_FILENAME /app/src/public/index.php;
|
|
include fastcgi_params;
|
|
}
|
|
}
|