From owner-freebsd-ports Fri Dec 21 3:44:44 2001 Delivered-To: freebsd-ports@freebsd.org Received: from zaphod.euronet.nl (zaphod.euronet.nl [194.134.128.241]) by hub.freebsd.org (Postfix) with ESMTP id 72F5137B41A; Fri, 21 Dec 2001 03:44:40 -0800 (PST) Received: (from ernst@localhost) by zaphod.euronet.nl (8.11.6/8.11.6) id fBLBif252175; Fri, 21 Dec 2001 12:44:41 +0100 (CET) (envelope-from ernst) Message-Id: <200112211144.fBLBif252175@zaphod.euronet.nl> Content-Type: text/plain; charset="iso-8859-1" From: Ernst de Haan To: ports@freebsd.org Subject: Starting a service after installation? Date: Fri, 21 Dec 2001 12:44:41 +0100 X-Mailer: KMail [version 1.3] MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Cc: Maxim Sobolev Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Hey all, How should services like an application server (i.e. www/orion or www/jakarta-tomcat) be started at boot time? I was thinking we could something like this, for example for www/orion: 1) During installation, install a script in ${PREFIX}/etc/rc.d. In this case orion.sh. Make it +x so it can be executed. The www/orion port (and a lot of other ports) already do this. 2) Make the script so that it checks if it should be started by reading /etc/rc.conf and /etc/defaults/rc.conf. For example, for www/orion, it could check for "start_orion". If this variable is not found, then the service is perhaps not started (or should it) ? If the variable *is* found then the service will only be started if the value matches [Yy][Ee][Ss] I'm also assuming that starting a service right after installation is a Bad Thing^TM. What about a 'make run' ? ;`/ Ernst -- Ernst de Haan EuroNet Internet B.V. "Come to me all who are weary and burdened and I will give you rest" -- Jesus Christ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message