New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Centos Apache Help
Hi.
I've been reading guides for the past few hours learning about web server security.
But they all say to never run apache as root and to always create a new user for each website and only give them permission to your websites directory so that incase your site gets hacked the only damage they can do would be in the website directory.
But I can't find a single tutorial that shows how to do all that.
I want to put my website in
/var/www/mydomain.com/public_html/
If anyone is wondering,, I am running Centos 6 32 bit on a VPS from ramnode
Comments
If a person were to hack your server, they would have access to all directories?
Yes but you know how in cPanel each website has it's own user and it's only allowed access to their folders.
Example, the user bob would only have access to everything inside /home/bob/
How do you do that without cPanel?
This is what control panels are for - creating system users etc. automatically. If you don't want to use cPanel then look at Virtualmin.
+1
A lot of people on here will moan and say learn how to do it through CLI but I agree, this is why we have control panels. I highly recommend Virtualmin as a free option if you don't want to buy cPanel.
Ok I will look into Virtualmin. Only reason I don't want to buy cPanel is because I only need to host one website which is a billing system for one of my online shops.
Use httpd.itk. Check these links for more info:
http://webtatic.com/packages/httpd-itk/
http://www.brancaleoni.com/blog/?page_id=17
virtualmin is also nice as it uses a relatively standard apache conf file file. so after you've added a site you can go and check out the conf files and learn from it....
Use vestacp.com.
Try this guide.
http://www.howtoforge.com/how-to-set-up-apache2-with-mod_fcgid-and-php5-on-centos-6.2
To do it without cpanel or any other panel, google "Apache Virtual Host"
Basically you will have to edit the apache configuration file to add a new virtual host and assign it to a linux user...