Apache install via Yast

Hello,

I want to install apache webserver with another homedirectory for users, so not the default ‘public_html’ but make a directory ‘webspace’ for users to upload their content. I read the conf files and there was said i had to change it in the apache.spec but when i install it these options ain’t there. So it would be nice if someone could give me a hint on how to achieve that?

Thanks in advange

Greetings,
Cb

very easy…

in /etc/apache2 you have a file listen.conf

look for the line that says: # NameVirtualHost *:80

remove the ‘#’

then in the same dir you have a dir named: vhosts.d

there you put your config file for each host / website

Thanks…

So i don’t need to rebuild apache ? to change the .spec file? So, for every user i make a virtual host ? Just checking to be sure :slight_smile:

here’s an config example:

<VirtualHost *:80>
ServerAdmin webmaster@dummy-host.example.com
ServerName name_of_your_site.com

ServerAlias 2nd_name_of_your_site.com

DocumentRoot /srv/www/vhosts/directory_to_yor_site

ErrorLog /var/log/apache2/sitename-error.log
CustomLog /var/log/apache2/sitename-access.log combined

HostnameLookups Off

UseCanonicalName Off

ServerSignature On

&lt;IfModule mod_userdir.c&gt;
    UserDir public_html
    Include /etc/apache2/mod_userdir.conf
&lt;/IfModule&gt;

&lt;Directory "/srv/www/vhosts/directory_to_yor_site"&gt;
    Options Indexes FollowSymLinks
    AllowOverride AuthConfig
    Order Allow,Deny
    Allow from all
&lt;/Directory&gt;

</VirtualHost>

there are 2 ways to achive what you want…

automaticly, then you need to change a lot of stuff (I guess)

or do it manually.

my choice would be manually because you have more control and do what you want.

if you wanna give users a http directory, accessable thru apache, then just create a bunch of virtual hosts.
For file upload you need something like ftp. there you make the start directory of each user, the same directory of the apache/virtualhost directory

But there are a loot of tools too, that can do the job.

look for example to syscp :wink:

Thanks…

That will do for the moment, i’ll get my hands to it…

For now, Have a lot of fun :wink: