From owner-freebsd-questions Fri Jun 8 6:39:43 2001 Delivered-To: freebsd-questions@freebsd.org Received: from antares.gecadsoftware.com (antares.gecadsoftware.com [193.230.167.76]) by hub.freebsd.org (Postfix) with SMTP id 4AF4D37B405 for ; Fri, 8 Jun 2001 06:39:37 -0700 (PDT) (envelope-from teo@gecadsoftware.com) Received: (qmail 56299 invoked from network); 8 Jun 2001 13:40:05 -0000 Received: from unknown (HELO taz.gecadsoftware.com) (193.230.245.17) by antares.gecadsoftware.com with SMTP; 8 Jun 2001 13:40:05 -0000 Received: from teo.gecadsoftware.com ([193.230.245.169]) by taz.gecadsoftware.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13) id M3427QRS; Fri, 8 Jun 2001 16:37:27 +0300 Received: (qmail 12696 invoked by uid 500); 8 Jun 2001 13:37:33 -0000 Date: Fri, 8 Jun 2001 16:37:33 +0300 From: teo@gecadsoftware.com To: freebsd-questions@FreeBSD.ORG Subject: Re: Different document roots for secure HTTP and HTTP Message-ID: <20010608163733.B12627@gecadsoftware.com> Reply-To: teo@gecadsoftware.com Mail-Followup-To: teo@gecadsoftware.com, freebsd-questions@FreeBSD.ORG References: <20010608122237.K98797@everest.wananchi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.15i In-Reply-To: <20010608122237.K98797@everest.wananchi.com>; from wash@wananchi.com on Fri, Jun 08, 2001 at 12:22:37PM +0300 Organization: GeCAD Software Comment: Worry less, RAV is watching! X-Operating-System: Linux 2.2.16 i686 up 1 day, 1:52 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi Odhiambo! On Fri, 08 Jun 2001, Odhiambo Washington wrote: > teo> > > :: Does anyone know if it possible to run Apache with > different ports for > teo> > > :: secure HTTP and ordinary HTTP. For example I want to run my > teo> > > :: port 443 (HTTPS) directed to document root /var/www-secure > teo> > > :: port 80 (HTTP) directed to document root /var/www > teo> > teo> give some more detail of what you want to achive. > > How does one start/run TWO binaries of the same app like apache? I am > interested in knowing HOWTO do that, especially stsrting them from rc.d/ > There is only one binary, httpd, and it will spawn child processes, to server clients from the network. It listens on both 80 and 443 ports, when it is configured so (this is done in the default httpd.conf -- after install, by adding configuration options depending on SSL variable definition via -D parameter to httpd.) httpd -DSSL or apachectl startssl(?) does that. here is my rc.d script (/usr/local/etc/rc.d/apache.sh) #!/bin/sh PATH=/usr/local/apache/bin:/usr/local/bin:/usr/bin:/bin export PATH case "$1" in start) echo -n "Starting Apache Web Server: httpd" apachectl start echo "." ;; stop) echo -n "Stopping Apache Web Server: httpd" apachectl stop echo "." ;; restart|fullstatus|status|graceful|configtest) apachectl $1 ;; help) apachectl | grep -v usage ;; *) echo "Usage: $0 {start|stop|restart|fullstatus|status|graceful|configtest|help}" exit 1 ;; esac exit 0 # end ciao -- teodor To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message