views:

24

answers:

1

Hey guys, I'm trying to have /blog redirecting to blog.mysubdomain.com Here's the location part in my nginx conf :

location /blog {
  proxy_set_header X-Real-IP $remote_addr;
  proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  proxy_set_header Host $http_host;
  proxy_redirect false;
  proxy_pass  http://blog.letitcast.com;
}

You can have a look here : http://letitcast.com/blog

It works but there's no CSS and I can't access /blog/wp-admin

Do you have an idea ?

Thanks

+1  A: 

Hi mike,
this should do the trick:

rewrite /blog/(.*) /$1 break;
louis
Thanks ! it worked like a charm :-)
Mike