Thanks for the advice. When I do it this way, I get an error (nginx error
log):
2010/10/03 00:27:33 [error] 20239#0: *6447
"/usr/local/nagios/share/nagios/index.php" is not found (2: No such file or
directory)
so you can see that nginx is adding /nagios/ to the end of the root
directory and so the file is not found (generating a 404 on the browser).
What would be the correct way to address this issue?
On Sat, Oct 2, 2010 at 9:03 PM, Edho P Arief <edhoprima@gmail.com> wrote:
> On Sun, Oct 3, 2010 at 7:23 AM, Ilan Berkner <iberkner@gmail.com> wrote:
> > Thanks,
> > I tried it using "root" in the location, still no luck.
> > Here's my config (the parts that matter), the location /nagios/ is what's
> > not working. What am I doing wrong? Thanks
>
> "not working"?
>
> - What are you expecting?
> - What are you getting?
>
> > http
> > {
> > root /var/www/html;
> > server
> > {
> > listen 10.0.1.163;
> > server_name dev.testsite.com;
> > location /nagios/
> > {
> > root /usr/local/nagios/share;
> > index index.php;
> > }
>
> as this one is located in different root path, you need additional php
> block
>
> location ~ ^/nagios/.*\.php$ {
> ...
> }
>
> --
> O< ascii ribbon campaign - stop html mail - www.asciiribbon.org
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://nginx.org/mailman/listinfo/nginx
>
_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx