4
4
4upik2018-04-01 20:39:18
PHP
4upik, 2018-04-01 20:39:18

How to write a fastcgi_read_timeout 1000 rule for a specific URL in Nginx?

How to write a fastcgi_read_timeout 1000 rule for a specific URL in Nginx?
Now the code is like this

location / {
  if (!-e $request_filename){
      rewrite ^(.*)$ /index.php;
          }
..........
        location ~* ^.+\.(jpeg|jpg|png|gif|bmp|ico|svg|css|js)$ {
            expires     max;
        }

        location ~ [^/]\.php(/|$) {
            fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
            if (!-f $document_root$fastcgi_script_name) {
                return  404;
            }

            fastcgi_pass    127.0.0.1:9001;
            fastcgi_index   index.php;
            include         /etc/nginx/fastcgi_params;
             }
    }

Answer the question

In order to leave comments, you need to log in

1 answer(s)
4
4upik, 2018-04-03
@4upik

location  ~ (.*)unikalnoeslovovurl(.*) {
include fastcgi_params;
    fastcgi_param SCRIPT_FILENAME $document_root/index.php;
        fastcgi_pass 127.0.0.1:9001;
 fastcgi_read_timeout 1000;
                         }

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question