From owner-freebsd-isp Mon Jul 15 14:54:58 2002 Delivered-To: freebsd-isp@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D73A237B401 for ; Mon, 15 Jul 2002 14:54:53 -0700 (PDT) Received: from supermail.mweb.co.za (supermail.mweb.co.za [196.2.53.171]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0347B43E3B for ; Mon, 15 Jul 2002 14:54:52 -0700 (PDT) (envelope-from savage@savage.za.org) Received: from [196.30.179.198] (helo=netsonic.megalan.co.za) by supermail.mweb.co.za with esmtp (Exim 3.22 #1) id 17UDPU-0002KB-00; Mon, 15 Jul 2002 23:29:37 +0200 Received: from genocide.megalan.co.za ([192.168.1.254] helo=genocide) by netsonic.megalan.co.za with smtp (Exim 3.36 #2) id 17UDo1-0001F3-47; Mon, 15 Jul 2002 23:54:58 +0200 Message-ID: <003f01c22c4a$23081710$fe01a8c0@genocide> From: "Chris Knipe" To: "Nick Rogness" , "George Georgalis" Cc: "Simon Carr's Palm 3 HandHeld" , "Gary D. Margiotta" , "Mark Johnston" , "'Odhiambo Washington'" , References: Subject: Re: Scripts to Manage Virtual Hosts Date: Mon, 15 Jul 2002 23:54:04 +0200 Organization: MegaLAN Corporate Networking Services MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Sender: owner-freebsd-isp@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Just FYI... I'm in the process of doing something similar for myself. It's a perl script configuring all my vhosts from a MySQL database, and works pretty need. I just rewrite clients.conf every say, 12 hours to replicate the changes made in the database, and gracefully restart apache. No headaches about removing hosts, because when the file is rewritten again, the deleted or deactivated vhosts won't be re-written to the conf file via the perl script. > > >include "/usr/local/etc/apache/VirtualHost/" > > FWIW, This approach does not work if you have FrontPage extension > enabled. It wants them all in the main httpd.conf file in order > to active fp exts via fpinstall. FP Ext, looks for ServerName, Port, ListenAddress and something else (there are four directives). A quick solution I found that I am using, is to have three files. httpd.conf (my main apache config) clients.conf (my clients and virtual hosts) fp.conf (hack fp ext). httpd.conf is a full propper configuration file, while clients.conf only contains entries. fp.conf is a combination of httpd.conf and clients.conf (all my vhosts, plus the required directives that fp ext needs), but is not used by any any software. I then just use FP Extensions, telling it that it should use fp.conf as the apache config, and whola. All sorted. > FP...What a joke... ^^^^^^^^^^ I can't agree more! -- me To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isp" in the body of the message