How to enable userdir?

#1
I'd like to enable userdir so users on shared IP can access their accounts by going to http://<ip>/~username

I followed the example in this docs and setup it as Static Context with no luck:
http://www.litespeedtech.com/docs/webserver/config/context/?hilite=userdir,

exp: ^/~([A-Za-z0-9]+)(.*)
location: /home/$1/www$2
accessible: yes
other options are not set

This is plain Centos server and I'm using Virtual Host templates to host these domains on the same shared IP.

What am I doing wrong?
 

mistwang

LiteSpeed Staff
#2
Which virtual host is reached when access the server with <IP>?
You need to configure a virtual host serve that and add context there. Using "/home/" as document root.
 

mistwang

LiteSpeed Staff
#4
You need to explicitly add the IP address as one of the domain alias for that vhost configured through the template.

turn on debug logging, and check which vhost is serving the request, which directory it is looking for.
 
#5
Thanks, it worked! :)
You really need to put that info in the docs or make it much easier, instead of defining the IP explicitly for each vhost template.
 
#6
Hmm wait, after I add the IP on domain aliases for each vhost template, I now see lots of these errors:

Hostname [ip] on listener [ip:80] is mapped to virtual host [xxx], can't map to virtual host [yyy]!

How do I get rid of these errors?
 
Top