From owner-freebsd-questions Tue Dec 29 13:40:25 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id NAA16358 for freebsd-questions-outgoing; Tue, 29 Dec 1998 13:40:25 -0800 (PST) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from corp.au.triax.com (slwag2p04.ozemail.com.au [203.108.157.52]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id NAA16349 for ; Tue, 29 Dec 1998 13:40:21 -0800 (PST) (envelope-from jim@corp.au.triax.com) Received: from localhost (jim@localhost) by corp.au.triax.com (8.9.1a/8.9.1) with ESMTP id IAA00690; Wed, 30 Dec 1998 08:30:03 +1100 (EST) Date: Wed, 30 Dec 1998 08:30:02 +1100 (EST) From: Jim Mock To: Marc Andre Paquin cc: freebsd-questions@FreeBSD.ORG Subject: Re: Multi-user web file structure on FreeBSD In-Reply-To: <368A6DC1.1A281F50@interresa.ca> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, 30 Dec 1998, Marc Andre Paquin wrote: [snip..] > In the book, I see that the default set up is: > /usr/local/www/data/ > An easy way to set it up is to use /usr/local/www/data for the apache root (as it is by default), and put all of the web pages for your site there. > With my new installation (version 2.2.7), I plan to have more than > a hundred clients with their own web pages. They will be able to > update some pages by FTP so security is a big concern. What is the > ideal tree? > The way I've got it set up is like this.. For example, if user bob wants www.bob.com, the section in httpd.conf for www.bob.com will look like this.. ServerAdmin bob@bob.com DocumentRoot /usr/home/bob/public_html-www.bob.com ServerName www.bob.com ErrorLog /usr/weblogs/www.bob.com-error_log TransferLog /usr/weblogs/www.bob.com-access_log ScriptAlias /cgi-bin/ /usr/home/bob/public_html-www.bob.com/cgi-bin/ Notice the DocumentRoot. That puts all of bob's web pages in public_html-www.bob.com in his home directory. If bob wanted to add a second domain, I'd set up another vhost in httpd.conf and point it to public_html-www.bob2.com in his home directory, etc. I also have the log files for bob from /usr/weblogs symlinked to a logs directory in his home directory so he can access them. Each user logs in via ftp with their own username and password and has access to only their home directory. Hope this helps, -- : Jim Mock | [jim@corp.au.triax.com] : : System Administrator | http://www.triax.com/ : : Triax Internet Services | ----------------------------- : : Portland, OR USA | FreeBSD: The Power to Serve : : Wagga Wagga, NSW Australia | http://www.freebsd.org/ : To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message