Welcome! Log In Create A New Profile

Advanced

Re: File Not Found logging in w/ nginx+phpMyAdmin in URL subdir

Elton Lima
April 16, 2012 03:36PM
Hi,

server {
        listen  80;
        server_name  localhost;
        #access_log  /var/log/nginx/access.log  main;

        location / {
            root   /var/www/nginx;
            index  index.php index.html index.htm;
        }

         location /phpmyadmin {
               root /usr/share/;
               index index.php index.html index.htm;
               location ~ ^/phpmyadmin/(.+\.php)$ {
                       try_files $uri =404;
                       root /usr/share/;
                       fastcgi_pass 127.0.0.1:9000;
                       fastcgi_index index.php;
                       fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
                       include /etc/nginx/fastcgi_params;
               }
               location ~* ^/phpmyadmin/(.+\.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ {
                       root /usr/share/;
               }
        }
        location /phpMyAdmin {
               rewrite ^/* /phpmyadmin last;
        }
}


 
Elton Lima
------------------------------------------------------
Analista de Suporte Linux
E-mail: eltonlim@gmail.com // eltlims@yahoo.com.br
Site: http://blog.eltonlima.com.br


________________________________
De: maria m. <lists@ruby-forum.com>
Para: nginx@nginx.org
Enviadas: Segunda-feira, 16 de Abril de 2012 15:27
Assunto: Re: File Not Found logging in w/ nginx+phpMyAdmin in URL subdir

server {
listen 80;
server_name support.example..com;
access_log /var/log/nginx/support.example.com.access.log;
error_log /var/log/nginx/support.example.com.error.log;

# this root dir below is to the thebuggenie htdocs folder
root /home/user/public_html/support.example.com/thebuggenie;
client_max_body_size 40M;
large_client_header_buffers 4 8k;
index index.php index.html;

location ^~ /files { }

#location ~ \..*/.*\.php$ { return 403; }

location ~ \.php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}

location ~ /(?<suburi>.*){
set $suburi $1;
try_files $uri $uri/ /index.php?url=$suburi&$args;
}

--
Posted via http://www.ruby-forum.com/.

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Re: File Not Found logging in w/ nginx+phpMyAdmin in URL subdir

maria m. April 16, 2012 02:28PM

Re: File Not Found logging in w/ nginx+phpMyAdmin in URL subdir

Elton Lima April 16, 2012 03:36PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 248
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready