From owner-freebsd-current@FreeBSD.ORG Tue Nov 5 18:28:18 2013 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 5BF61932 for ; Tue, 5 Nov 2013 18:28:18 +0000 (UTC) (envelope-from freebsd@allanjude.com) Received: from mx1.scaleengine.net (beauharnois2.bhs1.scaleengine.net [142.4.218.15]) by mx1.freebsd.org (Postfix) with ESMTP id 1706B2CB4 for ; Tue, 5 Nov 2013 18:28:17 +0000 (UTC) Received: from [10.1.1.1] (S01060001abad1dea.hm.shawcable.net [50.70.108.129]) (Authenticated sender: allan.jude@scaleengine.com) by mx1.scaleengine.net (Postfix) with ESMTPSA id 7D27544AA0 for ; Tue, 5 Nov 2013 18:28:14 +0000 (UTC) Message-ID: <527938C3.3000104@allanjude.com> Date: Tue, 05 Nov 2013 13:28:19 -0500 From: Allan Jude User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 MIME-Version: 1.0 To: freebsd-current@freebsd.org Subject: Re: cron(8) improvement References: <52792B60.1030309@allanjude.com> <52792CF3.9050104@mail.lifanov.com> <1383675687.8053.43379365.3F5A71FC@webmail.messagingengine.com> In-Reply-To: <1383675687.8053.43379365.3F5A71FC@webmail.messagingengine.com> X-Enigmail-Version: 1.6 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="mS8BBbj0is651lEMJ4L6VrsXCNOk0VFE3" X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Nov 2013 18:28:18 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --mS8BBbj0is651lEMJ4L6VrsXCNOk0VFE3 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 2013-11-05 13:21, Mark Felder wrote: > > On Tue, Nov 5, 2013, at 11:37, Nikolai Lifanov wrote: >> On 11/05/13 12:31, Allan Jude wrote: >>> This came up in discussion on IRC and I thought I should throw it at = the >>> list so I don't forget. >>> >>> A user was asking how to do what linux cron does, where there is a >>> directory /etc/cron.d/ that packages and add files to to create cront= abs. >>> >>> Making FreeBSD's cron (Vixie Cron) include /etc/cron.d/ and >>> /usr/local/etc/cron.d/ in the /etc/crontab format seems like a very >>> useful feature, especially for pkg(8) as it makes it easy and safe to= >>> programatically add and remove crontabs as part of a package. >>> >>> >> Shouldn't we encourage packages to use periodic(8) when possible? >> > Yes but our default periodic configuration in /etc/crontab is only > configured to be as granular as daily. If this is something that should= > run hourly or at very strange intervals then cron is a better choice. > > If the application is installing its own user they could install their > own crontab file in /var/cron/tabs. I'm certain I've seen a couple port= s > do this. > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.o= rg" I don't have a specific example off the top of my head, but I am sure there are some daemons that needs to do something at some interval as root. Personally I am not so sure about having a package create a crontab automatically. It seems like a POLA violation, but it is also something that seems to be expected by some modern applications. I assume it is mostly handled by pkg-message currently, and maybe it is best to continue that way, but having the additional flexibility may be very useful. If for nothing else, it would be a lot prettier than the way I currently manage crontabs using puppet. --=20 Allan Jude --mS8BBbj0is651lEMJ4L6VrsXCNOk0VFE3 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (MingW32) Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQIcBAEBAgAGBQJSeTjHAAoJEJrBFpNRJZKfE4AQALdb14F8E5kZh3ay8xMOD0Am Q8H2Av5AsBSM1jzqXDM9xY1fF3W60ePAYIKsGdwdsVW8eatrfFFf/5wNEzz6I0jo +aTMdYLegYSlzaC7xp7uLDRpNZq3dvejbAWSk96nHMQeclQ6yZgyakxe69j0j7KD /gvNNxR8INGa0MmcTKyUI9bkKK1H5jwgJY6S+z00enrdo3orvkYQN4axAqbk/EzV l/tWmgTPdVHyz/S7KmBb+mrdwSqpwlDEM9mhNrWQJfifJhfRvQv1GvLhDv3+QZ5S pgMjF0I7D+GmT2ds5cA+MUuR4gxYPziruOQvFpaVuq+w6qEu/tBoOYhgDXVF+Fyx fbIklfPcuiE9bjMPVdoifpHeeB7ZwvUSCWIiCNXm6T6SGaNtSfy5h2e5YOVmA6// f5cEwVBkwFAct6ivnkysh9iqM4uFUGpbakbGZeyykMMTc1FJU6FnJvLm60ogtQsz 5128AUCU6RucL7AJeIlTVqgDK28qguOf27WP7HWiQjy4ETAIvpiPwYpjUoX79flQ 8/YaZoEzapFhA4DD7kMAaAWBPxtkOH3pSUuewx8qtEGFLYb1k8HbVIgiZp4r+Z1k tfuzCER8UJYJtKq9ch6wjiW44p1dv9wCz9FqVyVoA+D3a/A3AxFhcVDBw+90ajM7 S1QmBd/reYBuaFztYMu3 =MbDX -----END PGP SIGNATURE----- --mS8BBbj0is651lEMJ4L6VrsXCNOk0VFE3--