0

Такая тема. Прикручиваю wordpress к laravel 5.1/ сервак nginx. на локалке и одном из продакшенов всё ок. на нужном сайте запросы идут через cloudflare (защищает и даёт ssl) выходит постоянный редирект. не могу разрулить. выносил как субдомен,всё ок.. настройки nginx`a

if ($host ~ '^www\.(.*)') {
    return 301 $scheme://$1$request_uri;
}

if ($request_uri ~ '(.*)/index\.php(.*)') {
    return 301 $1$2;
}

location / {
    index index.php;
    try_files $uri /index.php?$args;
}
location ~ "^(?<filename>.+\.php)($|/)" {
    include fastcgi_params;
    fastcgi_split_path_info ^(.+\.php)(.*);
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_buffers 64 64k; 
    #fastcgi_param HTTPS off;
    fastcgi_param HTTPS $fcgi_https;
    fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
}
location ^/blog/index.php(/.*)?$ {

    fastcgi_split_path_info ^(/blog/index.php)(/.+)$;
    fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
    fastcgi_index index.php;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_read_timeout 1000;
    fastcgi_param PATH_INFO $fastcgi_path_info;
        include fastcgi_params;
}

location /blog {
    index index.php;
    try_files $uri $uri/ blog/index.php?args;
    }

Что я упускаю, в чём конфликт??? ХЕЕЕЕЛЛЛППП Земляне!!!!

1 ответ 1

1

Всё вопрос закрыт. Была проблема в /blog - не указал root

Ваш ответ

By clicking “Отправить ответ”, you agree to our terms of service and acknowledge you have read our privacy policy.

Всё ещё ищете ответ? Посмотрите другие вопросы с метками или задайте свой вопрос.