From owner-freebsd-ports@FreeBSD.ORG Wed Jun 18 00:40:22 2008 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3C19A106566B for ; Wed, 18 Jun 2008 00:40:22 +0000 (UTC) (envelope-from pschmehl_lists@tx.rr.com) Received: from mail.stovebolt.com (mail.stovebolt.com [66.221.101.249]) by mx1.freebsd.org (Postfix) with ESMTP id EFCA48FC0A for ; Wed, 18 Jun 2008 00:40:21 +0000 (UTC) (envelope-from pschmehl_lists@tx.rr.com) Received: from [192.168.2.102] (cpe-24-175-90-48.tx.res.rr.com [24.175.90.48]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.stovebolt.com (Postfix) with ESMTPSA id BD7D011438F; Tue, 17 Jun 2008 19:40:14 -0500 (CDT) Date: Tue, 17 Jun 2008 19:40:19 -0500 From: Paul Schmehl To: David Hawthorne , freebsd-ports@freebsd.org Message-ID: <112A6326AC722E927FB2A41E@Macintosh.local> In-Reply-To: <746214C8-3863-4B29-8B01-230579284C76@bitgravity.com> References: <746214C8-3863-4B29-8B01-230579284C76@bitgravity.com> X-Mailer: Mulberry/4.0.8 (Mac OS X) X-Munged-Reply-To: To reply - figure it out MIME-Version: 1.0 Content-Type: multipart/signed; micalg=sha1; protocol="application/pkcs7-signature"; boundary="==========C4CC4C34F3AD6871FF59==========" X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Subject: Re: Question about ports adding cronjobs X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Paul Schmehl List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Jun 2008 00:40:22 -0000 --==========C4CC4C34F3AD6871FF59========== Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline --On June 17, 2008 3:24:11 PM -0700 David Hawthorne=20 wrote: > I have a piece of software I've been working on that gathers stats about > the local host and shoves them into rrd files, with an accompanying web > front-end page that generates pretty graphs from the RRDs on demand. I > have a package done up for it, and I'd like to add it to the ports tree > eventually, but I'm stuck on how to get it to automagically add the > cronjob to have the stats gathering script run every five minutes, and I > don't know of any ports that add cronjobs off the top of my head to go > look at. > > Is there an approved standard for doing this? It doesn't have to be as > root, either, it can run under a different user. Any advice on how to > get the port to add the user (and remove it properly when the port is > deinstalled) properly and securely would be appreciated as well. > Look at mail/courier/files/crontab.in,=20 mail/exim/files/POST-INSTALL_NOTES.clamd and mail/mailman/pkg-install (and = those ports' associated files) for some examples of ways to deal with cron = jobs in a port. Paul Schmehl If it isn't already obvious, my opinions are my own and not those of my employer. --==========C4CC4C34F3AD6871FF59==========--