Здавствуйте.

Есть файл /var/local/www/ssi_stub_memcahed/index.htmlс SSI вставками:

<html>
<body>
    <h1>SSI STUB MEMCACHED</h1>
    <p>Start include with stub</p>
    <!--# block name="one" -->!STUB!<!--# endblock -->
    <!--# include virtual="/ssi_stub_memcahed/include.html" stub="one" -->
    <p>End include with stub</p>
    <hr/>
    <p>Start include without stub</p>
    <!--# include virtual="/ssi_stub_memcahed/include.html" -->
    <p>End include without stub</p>
</body>
</html>

При запросе которого по http://localhost/ssi_stub_memcahed/index.htmlполучаемтакой результат:

<html>
<body>
    <h1>SSI STUB MEMCACHED</h1>
    <p>Start include with stub</p>
        !STUB!
    <p>End include with stub</p>
    <hr/>
    <p>Start include without stub</p>
    included successfully
    <p>End include without stub</p>
</body>
</html>


В файле /var/local/www/ssi_stub_memcahed/include.htmlзаписана строка:

included successfully

Конфигурация сервера:

server {
        listen                  80;
        server_name             localhost;

        location / {
                root            /etc/nginx/html;
                index           index.html index.htm;
        }

        location /nginx-status {
                stub_status     on;
                access_log      off;
                allow           127.0.0.1;
                deny            all;
        }

        location /ssi_stub_memcahed/{
                default_type text/html;
error_log /var/log/nginx/ssi_stub_memcahced.error debug;
access_log /var/log/nginx/ssi_stub_memcahced.access;
                error_page    404 502 504 =    @fallback;

                set    $memcached_key "test|$uri";
                memcached_connect_timeout     2;
                memcached_read_timeout        5;
                memcached_send_timeout        5;
                memcached_pass 127.0.0.1:11211;
        }

        location @fallback {
            root /var/local/www;
error_log /var/log/nginx/ssi_stub_memcahced_fallback.error debug;
            access_log /var/log/nginx/ssi_stub_memcahced_fallback.access;
            ssi on;
        }
}

Почему подключение со стабом работает так как будто произошла ошибка запроса, если этот файл очевидно есть и отдается со статусом 200?

--
С уважением, Туманов Александр

_______________________________________________
nginx-ru mailing list
[email protected]
http://mailman.nginx.org/mailman/listinfo/nginx-ru

Ответить