summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2009-01-08 06:13:46 +0000
committerMike Frysinger <vapier@gentoo.org>2009-01-08 06:13:46 +0000
commit95050f3fcc3d4217a4f8e8a3a9ce8fbc25670017 (patch)
treef7831482b5cd53517b6689cc10b3886749fc63ad /net-misc/rsync/rsync-3.0.5.ebuild
parentHave SRC_URI look in a slightly diff path where all upstream versions are kep... (diff)
downloadgentoo-2-95050f3fcc3d4217a4f8e8a3a9ce8fbc25670017.tar.gz
gentoo-2-95050f3fcc3d4217a4f8e8a3a9ce8fbc25670017.tar.bz2
gentoo-2-95050f3fcc3d4217a4f8e8a3a9ce8fbc25670017.zip
Drop code to move rsyncd.conf around since everyone is converted now #201223 by Paul Hewlett. Also tweak chroot check so it only warns when people have bad config files.
(Portage version: 2.2_rc20/cvs/Linux 2.6.28 x86_64)
Diffstat (limited to 'net-misc/rsync/rsync-3.0.5.ebuild')
-rw-r--r--net-misc/rsync/rsync-3.0.5.ebuild21
1 files changed, 7 insertions, 14 deletions
diff --git a/net-misc/rsync/rsync-3.0.5.ebuild b/net-misc/rsync/rsync-3.0.5.ebuild
index 2d7530a9e409..7d7dc8605f5f 100644
--- a/net-misc/rsync/rsync-3.0.5.ebuild
+++ b/net-misc/rsync/rsync-3.0.5.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/rsync/rsync-3.0.5.ebuild,v 1.2 2009/01/08 06:11:32 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/rsync/rsync-3.0.5.ebuild,v 1.3 2009/01/08 06:13:46 vapier Exp $
inherit eutils flag-o-matic toolchain-funcs autotools
@@ -53,14 +53,6 @@ src_compile() {
emake || die "emake failed"
}
-pkg_preinst() {
- if [[ -e ${ROOT}/etc/rsync/rsyncd.conf ]] && [[ ! -e ${ROOT}/etc/rsyncd.conf ]] ; then
- mv "${ROOT}"/etc/rsync/rsyncd.conf "${ROOT}"/etc/rsyncd.conf
- rm -f "${ROOT}"/etc/rsync/.keep
- rmdir "${ROOT}"/etc/rsync >& /dev/null
- fi
-}
-
src_install() {
emake DESTDIR="${D}" install || die "make install failed"
newconfd "${FILESDIR}"/rsyncd.conf.d rsyncd
@@ -79,9 +71,10 @@ src_install() {
}
pkg_postinst() {
- ewarn "The rsyncd.conf file has been moved for you to /etc/rsyncd.conf"
- echo
- ewarn "Please make sure you do NOT disable the rsync server running"
- ewarn "in a chroot. Please check /etc/rsyncd.conf and make sure"
- ewarn "it says: use chroot = yes"
+ if egrep -qs '^[[:space:]]use chroot[[:space:]]*=[[:space:]]*(no|0|false)' \
+ "${ROOT}"/etc/rsyncd.conf "${ROOT}"/etc/rsync/rsyncd.conf ; then
+ ewarn "You have disabled chroot support in your rsyncd.conf. This"
+ ewarn "is a security risk which you should fix. Please check your"
+ ewarn "/etc/rsyncd.conf file and fix the setting 'use chroot'."
+ fi
}