1 (edited by Leriss 2011-08-11 12:23:44)

Topic: DaNginx + mod_rewrite

Hello,

I just have a quick question - will mod_rewrite work correctly along with DaNginx or are there going to be needed some modifications to get it work properly ?

Re: DaNginx + mod_rewrite

There is no need  for  any changes . the mod_reqrite will be handled by apache on port 8888 after DAnginx installation .

Syslint Technologies | 24x7 Server Management | Outsourced Support | Software Development - (0091) 471-3273-211

3 (edited by panosru 2011-11-15 18:15:57)

Re: DaNginx + mod_rewrite

for me .htaccess files are completely ignored, when I access through port 80, also "nginx.conf" is ignored too. To sum up:

What I expected to be:

1) from port 80 nginx.conf should be detected by nginx
2) from port 8888 .htaccess should be detected by apache


What it actually do:

1) from port 80 nginx.conf is ignored by nginx
2) from port 8888 .htaccess is processed normally by apache.


Under the path: /home/****/domains/*****/public_html/css/ I have .htaccess file and nginx.conf file.

/home/****/domains/*****/public_html/css/.htaccess contents:

<IfModule mod_rewrite.c> 
    RewriteEngine on
    RewriteCond %{REQUEST_FILENAME} -f
    RewriteCond %{REQUEST_URI} \.css$
    RewriteCond %{QUERY_STRING} parse
    RewriteRule ^(.+)$ /Scaffold/index.php?f=%{REQUEST_URI}&%{QUERY_STRING}
</IfModule>

/home/****/domains/*****/public_html/css/nginx.conf contents:

if (-f $request_filename){
    set $rule_0 1$rule_0;
}
if ($uri ~ "\.css$"){
    set $rule_0 2$rule_0;
}
if ($args ~ "parse"){
    set $rule_0 3$rule_0;
}
if ($rule_0 = "321"){
    rewrite ^/(.+)$ /Scaffold/index.php?f=$uri&$args;
}

Thanks

EDIT:
Ok the htaccess was ignored because in /etc/danginx/gilestensions.txt I had to remove the css entry, so as I understood nginx process static content only, any other content is processed by apache. But is it possible to use nginx config instead of .htaccess files?

Thanks again.

Re: DaNginx + mod_rewrite

The .hatccess will be processed by apache .  You can add custom includes ,  please read the documentations .

Syslint Technologies | 24x7 Server Management | Outsourced Support | Software Development - (0091) 471-3273-211