Welcome! Log In Create A New Profile

Advanced

All paths expcept root/home path

Posted by xan4fun 
All paths expcept root/home path
May 05, 2015 04:22AM
Hi! I couldn figure this out until now :(

I want lol.gijoe.com to go to the root and every other paths like lol.gijoe.com/pathx or lol.gijoe.com/pathy/pathytz to go to somewhere else.

I found only solutions the other way around for specific paths /path and everything else / goes to index.

Do i have to specifiy each path speratatly?
Below example only does the proxy pass even though it should hit the home.
suggestions?


server {
server_name lol.gijoe.com
listen 80;

location = / {
root /home/www/;
}

location / {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_pass 172.0.0.0:1;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_max_temp_file_size 0;
}
}

Thank you very much!!



Edited 1 time(s). Last edit at 05/05/2015 04:22AM by xan4fun.
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 97
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready