| Nginx-ru mailing list archive (nginx-ru@sysoev.ru) [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
 rewrite
 
To: nginx-ru@xxxxxxxxxSubject: rewriteFrom: "Vasyl Kondrashov" <vasyl.kondrashov@xxxxxxxxx>Date: Wed, 10 Sep 2008 15:34:43 +0300Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed;        d=gmail.com; s=gamma;        h=domainkey-signature:received:received:message-id:date:from:to         :subject:mime-version:content-type:content-transfer-encoding         :content-disposition;        bh=7rcJdNFc0OFU4BtUo6EoDW4Epf4Ayjw1Z05xYCCK/KU=;        b=wv/ncmjmtqlvZYTC1PkIREYvB5WZdPH0OveYbzcxHgYa6tsLvdvem8EKJr02RUKIVQ         rO2PmGgB3aI0kyzlPcmVdXYWZ/PmIIZmqNKEi26lvJZHQz2K0Z1YshWVj5M+gqq0MJ8k         LRYiE2BAVY+iAdfrx7O5IRIzLxKalEhKHPe08=Domainkey-signature: a=rsa-sha1; c=nofws;        d=gmail.com; s=gamma;        h=message-id:date:from:to:subject:mime-version:content-type         :content-transfer-encoding:content-disposition;        b=wNgNE+imZTwPZEIfTxbRFkfoffJ8IlBHRtkXZnHoENQwQdADHHPk2w5KqZcg9Yo3T4         ST5U51FkQlj1zz4kV6G0wVs4IzWYE/LlEVs+UhvRy36kpQN/qiAEPEbyfg6yOmaYfP+f         Mca+DN6lePel/BoeNoihKvxX3gZeiTNTtM6Ec= 
 Добрый день всем!
Пытаюсь перевести rewrite из:
#________________________________________________________________________________________
           RewriteEngine on
           RewriteCond %{REQUEST_URI}            ^/server-status$ [OR]
           RewriteCond %{REQUEST_URI}            ^/server-info$ [OR]
           RewriteCond %{REQUEST_URI}            ^/whm-server-status$
           RewriteRule (.*)                      - [L]
           RewriteRule ^$                        index.php  [L]
                       RewriteRule ^sso_endpoint.php/ui$
index.php/SSO/UI [L]
                       RewriteRule ^sso_endpoint.php/SAML$
index.php/SSO/Proxy [L]
                       RewriteRule ^sso_endpoint.php/signout$
index.php/SSO/Proxy [L]
           RewriteCond %{REQUEST_URI}            ^/[a-z]+/.*$
           RewriteCond %{REQUEST_URI}            [^/]$
           RewriteRule (.*)                      -  [L]
           RewriteCond %{REQUEST_FILENAME}       !-f
           RewriteCond %{REQUEST_FILENAME}       !-d
           RewriteRule (.*)                      index.php/$1  [QSA,L]
 
#__________________________________________________________________________________________
в понятную nginx форму. Последний вариант:
 
#__________________________________________________________________________________________
if ($request_uri ~ ^/server-status$) {
break;
}
if ($request_uri ~ ^/server-info$) {
break;
}
if ($request_uri ~ ^/whm-server-status$) {
break;
}
rewrite ^$ index.php last;
rewrite ^sso_endpoint.php/ui$ index.php/SSO/UI last;
rewrite ^sso_endpoint.php/SAML$ index.php/SSO/Proxy last;
if ($request_uri ~ ^/[a-z]+/.*$) {
break;
}
#if ($request_uri ~ [^/]$) {
#break;
#}
if (!-e $request_filename) {
rewrite  ^/(.*)$  /index.php?$1$query_string  break;
}
 
#__________________________________________________________________________________________
Не получается желаемого :(
Пробовал  rewrite_log on; но не нашёл, куда он пишет :(
 |