Gentoo Archives: gentoo-admin

From: Robert Larson <robert@×××××××××.com>
To: gentoo-admin@l.g.o
Subject: Re: [gentoo-admin] shared gentoo linux hosting
Date: Thu, 13 Oct 2005 16:19:12
Message-Id: 200510131117.46276.robert@sixthings.com
In Reply to: [gentoo-admin] shared gentoo linux hosting by Okulov Vitaliy
1 Hello!
2
3 On Thursday 13 October 2005 10:24 am, Okulov Vitaliy wrote:
4 > Hi all. Somebody know how setup shared Gentoo linux hosting with Apache,
5 > MySQL, PHP, JDK.
6
7 Virtual Hosting:
8 This document covers installation and configuration:
9 http://gentoo-wiki.com/HOWTO_Linux_Virtual_Hosting_Server
10
11 Installation docs:
12 Here's some guides written about it:
13 http://gentoo-wiki.com/LAMP_Setup_Step_By_Step
14 http://www.gentoo.org/doc/en/java.xml
15
16 Or, here are the Wiki's if you need help:
17 http://gentoo-wiki.com/LAMP
18 http://gentoo-wiki.com/Java_Installation_Help
19
20 > With ability to modify apache config & crontab for user using ssh access?
21
22 As far as allowing the users to modify their own vhost settings, you would put
23 something like this in httpd.conf:
24 Include /(path to vhost file)/(user's vhost file).conf
25
26 You would have to have an entry for each user, so it might be better to have a
27 vhost list file that you might include in apache2.conf:
28 Include /etc/apache2/vhosts.list
29
30 And in vhosts.list put:
31 Include /(path to vhost file)/(user A's vhost file).conf
32 Include /(path to vhost file)/(user B's vhost file).conf
33 ...
34
35 If you put the appropriate user's permissions on those specific files, they
36 should be able to access them. Just make sure that apache has permission to
37 read them as well.
38
39 Something that you may want be concerned about though is that these people are
40 modifying your web server's configuration. You may want to find a way to
41 validate that these people aren't doing malicious things to their peices of
42 the configurations. This might be accomplished by running a program that
43 checks the files prior to restarting the server. Another concern is that
44 each time a configuration change is applied you will need to restart apache,
45 so "apachectl graceful" (or similar) would be ideal.
46
47 Perhaps a more viable solution than the one above may be to write a cgi script
48 that allows them to view their configuration, and modify it. Then upon
49 hitting "Apply", it might check it for errors or malicious options, write it
50 to a file, and restart the server.
51
52 With crontab, they should be able to type "crontab -e" and it should allow
53 them to modify it. If you are having trouble with that, then it probably
54 depends on which cron implementation you have. Some implementations require
55 that the user be in a certain group, and other's seem to just put strict
56 permissions on /usr/bin/crontab.
57
58 HTH,
59
60 Robert
61 --
62 gentoo-admin@g.o mailing list