From owner-freebsd-isp Tue Sep 12 16:43:36 2000 Delivered-To: freebsd-isp@freebsd.org Received: from thor.ghim.org (thor.ghim.org [209.249.182.115]) by hub.freebsd.org (Postfix) with ESMTP id 6AC7537B422 for ; Tue, 12 Sep 2000 16:43:32 -0700 (PDT) Received: from schvin.net (siddhartha.nexus [192.168.2.50]) by thor.ghim.org (8.10.1/8.10.1) with SMTP id e8CNhJ125432; Tue, 12 Sep 2000 23:43:19 GMT Received: by schvin.net (sSMTP sendmail emulation); Tue, 12 Sep 2000 23:43:18 +0000 Date: Tue, 12 Sep 2000 23:43:18 +0000 From: George Lewis To: Steve Price Cc: freebsd-isp@FreeBSD.ORG Subject: Re: named virtual hosts Message-ID: <20000912234318.K11511@schvin.net> References: <20000912184042.D55208@bsd.planetwe.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="fd5uyaI9j6xoeUBo" Content-Disposition: inline User-Agent: Mutt/1.2.4i In-Reply-To: <20000912184042.D55208@bsd.planetwe.com>; from sprice@hiwaay.net on Tue, Sep 12, 2000 at 06:40:42PM -0500 Sender: owner-freebsd-isp@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org --fd5uyaI9j6xoeUBo Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable You might think about creating some sort of file that has the specifics for each domain, and then write a nifty perl script that whips through it a= nd generates your httpd.conf, inserting defaults or specifics as the case may be. I guess that wouldn't necessarily make it more readable, but might help make it more maintainable and consistent. George Steve Price (sprice@hiwaay.net) wrote: > I have the following setup for Apache and was trying to reduce some > of the duplicate lines. What I have looks something like this. > Because this box will be hosting ~400 domains shortly I can't just > make the variables global. Well I can make some of them global by > using VirtualDocumentRoot and VirtualScriptAlias, but that doesn't > work for all the duplicated lines. >=20 > NameVirtualHost 192.168.21.21 > > DocumentRoot /home/foo/www > ServerName www.foo.com > ServerAdmin webmaster@foo.com > ErrorLog /home/foo/logs/error.log > TransferLog /home/foo/logs/access.log > ScriptAlias /cgi-bin/ /home/foo/cgi-bin/ > > > > DocumentRoot /home/foo/www > ServerName www.foo.com > ServerAdmin webmaster@foo.com > ErrorLog /home/foo/logs/error.log > TransferLog /home/foo/logs/access.log > ScriptAlias /cgi-bin/ /home/foo/cgi-bin/ > SSLEngine on > SSLCertificateFile /home/foo/ssl/ssl.crt > SSLCertificateKeyFile /home/foo/ssl/ssl.key > > >=20 > What I'd like to be able to do is something like this instead. >=20 > NameVirtualHost 192.168.21.21 > > DocumentRoot /home/foo/www > ServerName www.foo.com > ServerAdmin webmaster@foo.com > ErrorLog /home/foo/logs/error.log > TransferLog /home/foo/logs/access.log > ScriptAlias /cgi-bin/ /home/foo/cgi-bin/ > > # The following will not work. > # > # SSLEngine on > # SSLCertficateFile /home/foo/ssl/ssl.crt > # SSLCertficateKeyFile /home/foo/ssl/ssl.key > # > > >=20 > Any suggestions? Thanks. >=20 > -steve >=20 >=20 > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-isp" in the body of the message --=20 George Lewis http://schvin.net/ --fd5uyaI9j6xoeUBo Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.2 (OpenBSD) Comment: For info see http://www.gnupg.org iD8DBQE5vr+VpwNd2qfAniwRAhMWAJ9NHgnjENgZv549k+8TAD8KMKlvxQCghbp9 lbedmTqesZIE4h1u7XE14vA= =RMj7 -----END PGP SIGNATURE----- --fd5uyaI9j6xoeUBo-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isp" in the body of the message