954,178 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

vsftpd & httpd

Hi,

I am running FC4 and my website successfully. I have sort of stumbled onto a different avenue. I finally got my vsftpd to allow users to log into the server as long as their home directory is set to /home/(user), (user) being their login. I have the web page in the /var/www/(user) directory. Is it possible for me to modify my httpd.conf file to allow the webpages be displayed while the files are in their home directory? For instance, if I am hosting a website about Fish, and I create a directory in /home/fish for the
user, can I have index.html in /home/fish directory and be able to get to it without it being in /var/www? I am sure I can modify the httpd.conf file but I am not sure how to do it.

Thanks,

Chris

cdawley4
Newbie Poster
7 posts since Jul 2005
Reputation Points: 10
Solved Threads: 0
 

maybe this is what you're looking for:

http://httpd.apache.org/docs-2.0/urlmapping.html

alc6379
Cookie... That's it
Team Colleague
2,820 posts since Dec 2003
Reputation Points: 186
Solved Threads: 147
 

That is sort of what I was looking for, but I thought if you uncomment the UserDir public_html enable, it would allow you to use their home directory. I tried to enable that option and put the index.html under the user's home directory and got the Apache maintenance page. Is there anything else I need to do or will the redirect fix it?

cdawley4
Newbie Poster
7 posts since Jul 2005
Reputation Points: 10
Solved Threads: 0
 

Oh yeah!

You'll have to excuse me-- I'm not sitting in front of a system with Apache on it right now.

You just make a public_html folder in the user's directory, and put the files there. That way, when you type:

http://webserver ip/~username

The page will show up that you put in /home/username/public_html

alc6379
Cookie... That's it
Team Colleague
2,820 posts since Dec 2003
Reputation Points: 186
Solved Threads: 147
 

Here is my httpd.conf file. I am going to list just the stuff I changed. Everything else is default.

UseCanonicalName On #UserDir disable UserDir public_html

AllowOverride FileInfo AuthConfig Limit Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec Order allow,deny Allow from all Order deny,allow Deny from all

DirectoryIndex index.html index.html.var

AccessFileName .htaccess

When I restart my httpd service, I get DocumentRoot must be a directory. Does the documentroot have to be /var/www?

Thanks,

Chris

cdawley4
Newbie Poster
7 posts since Jul 2005
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: