diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2008-12-05 08:25:52 +0000 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2008-12-05 08:25:52 +0000 |
commit | bcefc293a4cd4223c8bc388bb1db356246f1cb23 (patch) | |
tree | c7006ab5fbdb4477e15b7ed0d45dae6196fa844b /net-misc/cfengine | |
parent | Avoid a collision on the lock names inside the packages method when the packa... (diff) | |
download | gentoo-2-bcefc293a4cd4223c8bc388bb1db356246f1cb23.tar.gz gentoo-2-bcefc293a4cd4223c8bc388bb1db356246f1cb23.tar.bz2 gentoo-2-bcefc293a4cd4223c8bc388bb1db356246f1cb23.zip |
Bug #124314 - implement ROOT support. cfkeys must be run with ROOT==/, but is not run until emerge --config now.
(Portage version: 2.2_rc16/cvs/Linux 2.6.28-rc5-00117-g7f0f598 x86_64)
Diffstat (limited to 'net-misc/cfengine')
-rw-r--r-- | net-misc/cfengine/ChangeLog | 7 | ||||
-rw-r--r-- | net-misc/cfengine/cfengine-2.2.8-r1.ebuild | 24 |
2 files changed, 22 insertions, 9 deletions
diff --git a/net-misc/cfengine/ChangeLog b/net-misc/cfengine/ChangeLog index 3e3bf63e3bbf..8004df9f6d12 100644 --- a/net-misc/cfengine/ChangeLog +++ b/net-misc/cfengine/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for net-misc/cfengine # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-misc/cfengine/ChangeLog,v 1.88 2008/12/05 08:17:26 robbat2 Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-misc/cfengine/ChangeLog,v 1.89 2008/12/05 08:25:52 robbat2 Exp $ + + 05 Dec 2008; Robin H. Johnson <robbat2@gentoo.org> + cfengine-2.2.8-r1.ebuild: + Bug #124314 - implement ROOT support. cfkeys must be run with ROOT==/, but + is not run until emerge --config now. *cfengine-2.2.8-r1 (05 Dec 2008) *cfengine-2.1.22-r2 (05 Dec 2008) diff --git a/net-misc/cfengine/cfengine-2.2.8-r1.ebuild b/net-misc/cfengine/cfengine-2.2.8-r1.ebuild index fef5a86f8ed9..e1e8e3c82d2b 100644 --- a/net-misc/cfengine/cfengine-2.2.8-r1.ebuild +++ b/net-misc/cfengine/cfengine-2.2.8-r1.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2008 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-misc/cfengine/cfengine-2.2.8-r1.ebuild,v 1.1 2008/12/05 08:17:26 robbat2 Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-misc/cfengine/cfengine-2.2.8-r1.ebuild,v 1.2 2008/12/05 08:25:52 robbat2 Exp $ inherit eutils @@ -63,18 +63,12 @@ src_install() { } pkg_postinst() { - if [ ! -f "/var/cfengine/ppkeys/localhost.priv" ] - then - einfo "Generating keys for localhost." - /usr/sbin/cfkey - fi - # Copy cfagent into the cfengine tree otherwise cfexecd won't # find it. Most hosts cache their copy of the cfengine # binaries here. This is the default search location for the # binaries. - cp /usr/sbin/cf{agent,servd,execd} /var/cfengine/bin/ + cp -f /usr/sbin/cf{agent,servd,execd} "${ROOT}"/var/cfengine/bin/ einfo einfo "NOTE: The cfportage module has been deprecated in favor of the" @@ -85,4 +79,18 @@ pkg_postinst() { einfo "To run cfengine out of cron every half hour modify your crontab:" einfo "0,30 * * * * /usr/sbin/cfexecd -F" einfo + + elog "You MUST generate the keys for cfengine by running:" + elog "emerge --config ${CATEGORY}/${PN}" +} + +pkg_config() { + if [ "${ROOT}" == "/" ]; then + if [ ! -f "/var/cfengine/ppkeys/localhost.priv" ]; then + einfo "Generating keys for localhost." + /usr/sbin/cfkey + fi + else + die "cfengine cfkey does not support any value of ROOT other than /." + fi } |