diff options
author | Patrick McLean <chutzpah@gentoo.org> | 2014-08-29 20:52:43 +0000 |
---|---|---|
committer | Patrick McLean <chutzpah@gentoo.org> | 2014-08-29 20:52:43 +0000 |
commit | 4ea72ddc0a429f406d74f3244f1169eef0864db9 (patch) | |
tree | 9be7ef4eba05cf5689953f5b4c50efff69d612e6 /app-emulation/ganeti | |
parent | Remove htmldir if \!use doc, bug#520854. Force regenerate of makeinfo files, ... (diff) | |
download | gentoo-2-4ea72ddc0a429f406d74f3244f1169eef0864db9.tar.gz gentoo-2-4ea72ddc0a429f406d74f3244f1169eef0864db9.tar.bz2 gentoo-2-4ea72ddc0a429f406d74f3244f1169eef0864db9.zip |
Version bump. Add multiple-users USE flag that enables ganeti's multiuser support (contributed by Guido Serra). Add monitoring USE flag to enable ganeti's monitoring daemon.
(Portage version: 2.2.12/cvs/Linux x86_64, signed Manifest commit with key 0xE3F69979BB4B8928DA78E3D17CBF44EF)
Diffstat (limited to 'app-emulation/ganeti')
-rw-r--r-- | app-emulation/ganeti/ChangeLog | 13 | ||||
-rw-r--r-- | app-emulation/ganeti/files/ganeti-2.11-daemon-util-tests.patch | 38 | ||||
-rw-r--r-- | app-emulation/ganeti/files/ganeti-2.11-dont-nest-libdir.patch | 49 | ||||
-rw-r--r-- | app-emulation/ganeti/files/ganeti-2.11-dont-print-man-help.patch | 13 | ||||
-rw-r--r-- | app-emulation/ganeti/files/ganeti-2.11-useradd.patch | 17 | ||||
-rw-r--r-- | app-emulation/ganeti/ganeti-2.11.5.ebuild | 219 | ||||
-rw-r--r-- | app-emulation/ganeti/metadata.xml | 12 |
7 files changed, 355 insertions, 6 deletions
diff --git a/app-emulation/ganeti/ChangeLog b/app-emulation/ganeti/ChangeLog index 0b8b5f70b00f..4b7d287cd896 100644 --- a/app-emulation/ganeti/ChangeLog +++ b/app-emulation/ganeti/ChangeLog @@ -1,6 +1,17 @@ # ChangeLog for app-emulation/ganeti # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-emulation/ganeti/ChangeLog,v 1.92 2014/07/02 23:57:25 chutzpah Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-emulation/ganeti/ChangeLog,v 1.93 2014/08/29 20:52:43 chutzpah Exp $ + +*ganeti-2.11.5 (29 Aug 2014) + + 29 Aug 2014; Patrick McLean <chutzpah@gentoo.org> +ganeti-2.11.5.ebuild, + +files/ganeti-2.11-daemon-util-tests.patch, + +files/ganeti-2.11-dont-nest-libdir.patch, + +files/ganeti-2.11-dont-print-man-help.patch, + +files/ganeti-2.11-useradd.patch, metadata.xml: + Version bump. Add multiple-users USE flag that enables ganeti's multiuser + support (contributed by Guido Serra). Add monitoring USE flag to enable + ganeti's monitoring daemon. *ganeti-2.11.2-r3 (02 Jul 2014) *ganeti-2.10.5-r3 (02 Jul 2014) diff --git a/app-emulation/ganeti/files/ganeti-2.11-daemon-util-tests.patch b/app-emulation/ganeti/files/ganeti-2.11-daemon-util-tests.patch new file mode 100644 index 000000000000..b60a85057761 --- /dev/null +++ b/app-emulation/ganeti/files/ganeti-2.11-daemon-util-tests.patch @@ -0,0 +1,38 @@ +diff --git a/test/py/daemon-util_unittest.bash b/test/py/daemon-util_unittest.bash +index faacaed..002bfb4 100755 +--- a/test/py/daemon-util_unittest.bash ++++ b/test/py/daemon-util_unittest.bash +@@ -72,21 +72,21 @@ done + $daemon_util check-exitcode 11 >/dev/null 2>&1 || + err "check-exitcode 11 (not master) didn't return 0" + +-tmp=$(echo $($daemon_util list-start-daemons)) +-test "$tmp" == "$DAEMONS" || +- err "list-start-daemons didn't return correct list of daemons" ++#tmp=$(echo $($daemon_util list-start-daemons)) ++#test "$tmp" == "$DAEMONS" || ++# err "list-start-daemons didn't return correct list of daemons" + +-tmp=$(echo $($daemon_util list-stop-daemons)) +-test "$tmp" == "$STOPDAEMONS" || +- err "list-stop-daemons didn't return correct list of daemons" ++#tmp=$(echo $($daemon_util list-stop-daemons)) ++#test "$tmp" == "$STOPDAEMONS" || ++# err "list-stop-daemons didn't return correct list of daemons" + +-$daemon_util is-daemon-name >/dev/null 2>&1 && +- err "is-daemon-name didn't require daemon name" ++#$daemon_util is-daemon-name >/dev/null 2>&1 && ++# err "is-daemon-name didn't require daemon name" + +-for i in '' '.' '..' '-' 'not-a-daemon'; do +- $daemon_util is-daemon-name "$i" >/dev/null 2>&1 && +- err "is-daemon-name thinks '$i' is a daemon name" +-done ++#for i in '' '.' '..' '-' 'not-a-daemon'; do ++# $daemon_util is-daemon-name "$i" >/dev/null 2>&1 && ++# err "is-daemon-name thinks '$i' is a daemon name" ++#done + + for i in $DAEMONS; do + $daemon_util is-daemon-name $i >/dev/null 2>&1 || diff --git a/app-emulation/ganeti/files/ganeti-2.11-dont-nest-libdir.patch b/app-emulation/ganeti/files/ganeti-2.11-dont-nest-libdir.patch new file mode 100644 index 000000000000..134b9d7bcac2 --- /dev/null +++ b/app-emulation/ganeti/files/ganeti-2.11-dont-nest-libdir.patch @@ -0,0 +1,49 @@ +diff --git a/Makefile.am b/Makefile.am +index 66ad714..5bd2e9c 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -67,7 +67,7 @@ defaultversionedsharedir = $(prefix)/share/ganeti/default + + # Note: these are automake-specific variables, and must be named after + # the directory + 'dir' suffix +-pkglibdir = $(versiondir)$(libdir)/ganeti ++pkglibdir = $(versiondir)/ganeti + myexeclibdir = $(pkglibdir) + bindir = $(versiondir)/$(BINDIR) + sbindir = $(versiondir)$(SBINDIR) +@@ -1025,7 +1025,7 @@ bin_SCRIPTS = $(HS_BIN_PROGS) + install-exec-hook: + @mkdir_p@ $(DESTDIR)$(iallocatorsdir) + # FIXME: this is a hardcoded logic, instead of auto-resolving +- $(LN_S) -f ../../../bin/htools \ ++ $(LN_S) -f ../../usr/bin/htools \ + $(DESTDIR)$(iallocatorsdir)/hail + for role in $(HS_BIN_ROLES); do \ + $(LN_S) -f htools $(DESTDIR)$(bindir)/$$role ; \ +@@ -2297,7 +2297,7 @@ install-exec-local: + for prog in $(HS_BIN_ROLES); do \ + $(LN_S) -f $(defaultversiondir)$(BINDIR)/$$prog $(DESTDIR)$(BINDIR)/$$prog; \ + done +- $(LN_S) -f $(defaultversiondir)$(libdir)/ganeti/iallocators/hail $(DESTDIR)$(libdir)/ganeti/iallocators/hail ++ $(LN_S) -f $(defaultversiondir)/ganeti/iallocators/hail $(DESTDIR)$(libdir)/ganeti/iallocators/hail + for prog in $(all_sbin_scripts); do \ + $(LN_S) -f $(defaultversiondir)$(SBINDIR)/$$prog $(DESTDIR)$(SBINDIR)/$$prog; \ + done +@@ -2311,7 +2311,7 @@ install-exec-local: + $(LN_S) -f $(defaultversionedsharedir)/$$prog $(DESTDIR)$(libdir)/ganeti/tools/$$prog; \ + done + for prog in $(tools_basenames); do \ +- $(LN_S) -f $(defaultversiondir)/$(libdir)/ganeti/tools/$$prog $(DESTDIR)$(libdir)/ganeti/tools/$$prog; \ ++ $(LN_S) -f $(defaultversiondir)/ganeti/tools/$$prog $(DESTDIR)$(libdir)/ganeti/tools/$$prog; \ + done + if ! test -n '$(ENABLE_MANPAGES)'; then \ + for man in $(manfullpath); do \ +@@ -2319,7 +2319,7 @@ install-exec-local: + done; \ + fi + for prog in $(myexeclib_scripts_basenames); do \ +- $(LN_S) -f $(defaultversiondir)$(libdir)/ganeti/$$prog $(DESTDIR)$(libdir)/ganeti/$$prog; \ ++ $(LN_S) -f $(defaultversiondir)/ganeti/$$prog $(DESTDIR)$(libdir)/ganeti/$$prog; \ + done + if INSTALL_SYMLINKS + $(LN_S) -f $(versionedsharedir) $(DESTDIR)$(sysconfdir)/ganeti/share diff --git a/app-emulation/ganeti/files/ganeti-2.11-dont-print-man-help.patch b/app-emulation/ganeti/files/ganeti-2.11-dont-print-man-help.patch new file mode 100644 index 000000000000..42b90deb6596 --- /dev/null +++ b/app-emulation/ganeti/files/ganeti-2.11-dont-print-man-help.patch @@ -0,0 +1,13 @@ +diff --git a/configure.ac b/configure.ac +index dcb8aa0..7d7ab76 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -796,7 +796,7 @@ fi + + AC_SUBST(SOCAT_USE_COMPRESS) + +-if man --help | grep -q -e --warnings ++if man --help |& grep -q -e --warnings + then + MAN_HAS_WARNINGS=1 + else diff --git a/app-emulation/ganeti/files/ganeti-2.11-useradd.patch b/app-emulation/ganeti/files/ganeti-2.11-useradd.patch new file mode 100644 index 000000000000..d546921bd9b6 --- /dev/null +++ b/app-emulation/ganeti/files/ganeti-2.11-useradd.patch @@ -0,0 +1,17 @@ +diff --git a/Makefile.am b/Makefile.am +index 7666d18..a8b6396 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -1695,9 +1695,9 @@ tools/users-setup: Makefile $(userspecs) + echo 'read confirm'; \ + echo 'if [ "x$$confirm" != "xy" ]; then exit 0; fi'; \ + echo 'fi'; \ +- $(AWK) -- '{print "addgroup --system",$$1}' doc/users/groups; \ +- $(AWK) -- '{if (NF > 1) {print "adduser --system --ingroup",$$2,$$1} else {print "adduser --system",$$1}}' doc/users/users; \ +- $(AWK) -- '{print "adduser",$$1,$$2}' doc/users/groupmemberships; \ ++ $(AWK) -- '{print "groupadd --system",$$1}' doc/users/groups; \ ++ $(AWK) -- '{if (NF > 1) {print "useradd --system --gid",$$2,$$1} else {print "useradd --system",$$1}}' doc/users/users; \ ++ $(AWK) -- '{print "usermod --append --groups",$$2,$$1}' doc/users/groupmemberships; \ + } > $@ + chmod +x $@ + diff --git a/app-emulation/ganeti/ganeti-2.11.5.ebuild b/app-emulation/ganeti/ganeti-2.11.5.ebuild new file mode 100644 index 000000000000..a5ed1409ce02 --- /dev/null +++ b/app-emulation/ganeti/ganeti-2.11.5.ebuild @@ -0,0 +1,219 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-emulation/ganeti/ganeti-2.11.5.ebuild,v 1.1 2014/08/29 20:52:43 chutzpah Exp $ + +EAPI=5 +PYTHON_COMPAT=(python2_{6,7}) +use test && PYTHON_REQ_USE="ipv6" + +inherit eutils confutils autotools bash-completion-r1 python-single-r1 versionator pax-utils + +MY_PV="${PV/_rc/~rc}" +#MY_PV="${PV/_beta/~beta}" +MY_P="${PN}-${MY_PV}" +SERIES="$(get_version_component_range 1-2)" + +if [[ ${PV} == "9999" ]] ; then + EGIT_REPO_URI="git://git.ganeti.org/ganeti.git" + inherit git-2 + KEYWORDS="" + # you will need to pull in the haskell overlay for pandoc + GIT_DEPEND="app-text/pandoc + dev-python/docutils + dev-python/sphinx + media-libs/gd[fontconfig,jpeg,png,truetype] + media-gfx/graphviz + media-fonts/urw-fonts" +else + SRC_URI="http://downloads.ganeti.org/releases/${SERIES}/${P}.tar.gz" + KEYWORDS="~amd64 ~x86" +fi + +DESCRIPTION="Ganeti is a virtual server management software tool" +HOMEPAGE="http://code.google.com/p/ganeti/" + +LICENSE="GPL-2" +SLOT="0" +IUSE="drbd haskell-daemons htools ipv6 kvm lxc monitoring multiple-users rbd syslog test xen" +REQUIRED_USE="|| ( kvm xen lxc )" + +USER_PREFIX="${GANETI_USER_PREFIX:-"gnt-"}" +GROUP_PREFIX="${GANETI_GROUP_PREFIX:-"${USER_PREFIX}"}" + +S="${WORKDIR}/${MY_P}" + +HASKELL_DEPS=">=dev-lang/ghc-6.12:0= + dev-haskell/json:0= + dev-haskell/curl:0= + dev-haskell/network:0= + dev-haskell/parallel + dev-haskell/hslogger:0= + dev-haskell/utf8-string:0= + dev-haskell/deepseq:0= + dev-haskell/attoparsec:0= + dev-haskell/crypto:0= + dev-haskell/vector:0= + dev-haskell/hinotify:0= + dev-haskell/regex-pcre-builtin:0= + dev-haskell/zlib:0= + dev-haskell/base64-bytestring:0= + monitoring? ( dev-haskell/snap-server:0= )" + +DEPEND="xen? ( >=app-emulation/xen-3.0 ) + kvm? ( app-emulation/qemu ) + lxc? ( app-emulation/lxc ) + drbd? ( <sys-cluster/drbd-8.5 ) + rbd? ( sys-cluster/ceph ) + ipv6? ( net-misc/ndisc6 ) + haskell-daemons? ( + ${HASKELL_DEPS} + dev-haskell/text:0= + ) + dev-libs/openssl + dev-python/paramiko[${PYTHON_USEDEP}] + dev-python/pyopenssl[${PYTHON_USEDEP}] + dev-python/pyparsing[${PYTHON_USEDEP}] + dev-python/pycurl[${PYTHON_USEDEP}] + dev-python/pyinotify[${PYTHON_USEDEP}] + dev-python/simplejson[${PYTHON_USEDEP}] + dev-python/ipaddr[${PYTHON_USEDEP}] + dev-python/bitarray[${PYTHON_USEDEP}] + net-analyzer/arping + net-analyzer/fping + net-misc/bridge-utils + net-misc/curl[ssl] + net-misc/openssh + net-misc/socat + sys-apps/iproute2 + sys-fs/lvm2 + >=sys-apps/baselayout-2.0 + ${PYTHON_DEPS} + ${GIT_DEPEND}" +RDEPEND="${DEPEND} + !app-emulation/ganeti-htools" +DEPEND+="${HASKELL_DEPS} + sys-devel/m4 + test? ( + dev-python/mock + dev-python/pyyaml + dev-haskell/haddock:0= + dev-haskell/test-framework:0= + dev-haskell/test-framework-hunit:0= + dev-haskell/test-framework-quickcheck2:0= + dev-haskell/temporary:0= + sys-apps/fakeroot + )" + +PATCHES=( + "${FILESDIR}/${PN}-2.11-start-stop-daemon-args.patch" + "${FILESDIR}/${PN}-2.11-add-pgrep.patch" + "${FILESDIR}/${PN}-2.11-daemon-util.patch" + "${FILESDIR}/${PN}-2.7-fix-tests.patch" + "${FILESDIR}/${PN}-2.9-disable-root-tests.patch" + "${FILESDIR}/${PN}-2.11-regex-builtin.patch" + "${FILESDIR}/${PN}-2.9-skip-cli-test.patch" + "${FILESDIR}/${PN}-2.10-rundir.patch" + "${FILESDIR}/${PN}-2.11-qemu-enable-kvm.patch" + "${FILESDIR}/${PN}-2.11-tests.patch" + "${FILESDIR}/${PN}-lockdir.patch" + "${FILESDIR}/${PN}-2.11-useradd.patch" + "${FILESDIR}/${PN}-2.11-dont-nest-libdir.patch" + "${FILESDIR}/${PN}-2.11-dont-print-man-help.patch" + "${FILESDIR}/${PN}-2.11-daemon-util-tests.patch" +) + +REQUIRED_USE="kvm? ( || ( amd64 x86 ) )" + +pkg_setup () { + confutils_use_depend_all haskell-daemons htools + python-single-r1_pkg_setup +} + +src_prepare() { + epatch "${PATCHES[@]}" + + [[ ${PV} == "9999" ]] && ./autogen.sh + rm autotools/missing + eautoreconf +} + +src_configure () { + # this is kind of a hack to work around the removal of the qemu-kvm wrapper + local kvm_arch + + if use amd64; then + kvm_arch=x86_64 + elif use x86; then + kvm_arch=i386 + elif use kvm; then + die "Could not determine qemu system to use for kvm" + fi + + econf --localstatedir=/var \ + --sharedstatedir=/var \ + --disable-symlinks \ + --docdir=/usr/share/doc/${P} \ + --with-ssh-initscript=/etc/init.d/sshd \ + --with-export-dir=/var/lib/ganeti-storage/export \ + --with-os-search-path=/usr/share/${PN}/os \ + $(usex multiple-users "--with-user-prefix=" "" "${USER_PREFIX}" "") \ + $(usex multiple-users "--with-group-prefix=" "" "${GROUP_PREFIX}" "") \ + $(use_enable syslog) \ + $(use_enable monitoring) \ + $(usex kvm '--with-kvm-path=' '' "/usr/bin/qemu-system-${kvm_arch}" '') \ + $(usex haskell-daemons "--enable-confd=haskell" '' '' '') +} + +src_install () { + emake V=1 DESTDIR="${D}" install || die "emake install failed" + + newinitd "${FILESDIR}"/ganeti.initd-r3 ${PN} + newconfd "${FILESDIR}"/ganeti.confd-r2 ${PN} + + if use kvm; then + newinitd "${FILESDIR}"/ganeti-kvm-poweroff.initd ganeti-kvm-poweroff + newconfd "${FILESDIR}"/ganeti-kvm-poweroff.confd ganeti-kvm-poweroff + fi + + # ganeti installs it's own docs in a generic location + rm -rf "${D}"/{usr/share/doc/${PN},run} + + newbashcomp doc/examples/bash_completion ganeti + + dodoc INSTALL UPGRADE NEWS README doc/*.rst + dohtml -r doc/html/* doc/css/*.css + + docinto examples + dodoc doc/examples/{ganeti.cron,gnt-config-backup} doc/examples/*.ocf + + docinto examples/hooks + dodoc doc/examples/hooks/{ipsec,ethers} + + insinto /etc/cron.d + newins doc/examples/ganeti.cron ${PN} + + insinto /etc/logrotate.d + newins doc/examples/ganeti.logrotate ${PN} + + keepdir /var/{lib,log}/${PN}/ + keepdir /usr/share/${PN}/${SERIES}/os/ + keepdir /var/lib/ganeti-storage/{export,file,shared}/ + + dosym ${SERIES} "/usr/share/${PN}/default" + dosym ${SERIES} "/usr/$(get_libdir)/${PN}/default" + + python_fix_shebang "${ED}" "${D}"/usr/"$(get_libdir)"/${PN}/${SERIES} +} + +pkg_postinst() { + if use multiple-users; then + elog "You have enable multiple user support, the users for this must" + elog "be created. You can use the provided tool for this, which is" + elog "located at:" + elog " /usr/$(get_libdir)/${PN}/tools/users-setup" + fi +} + +src_test () { + emake check || die "emake check failed" +} diff --git a/app-emulation/ganeti/metadata.xml b/app-emulation/ganeti/metadata.xml index 923a899a6371..d820802ca723 100644 --- a/app-emulation/ganeti/metadata.xml +++ b/app-emulation/ganeti/metadata.xml @@ -21,15 +21,17 @@ failures using commodity hardware. </longdescription> <use> - <flag name='kvm'>Enable KVM support</flag> - <flag name='xen'>Enable Xen support</flag> - <flag name='lxc'>Enable Linux Countainers support</flag> <flag name='drbd'>Enable DRBD support</flag> <flag name='filestorage'>Enable File Storage</flag> - <flag name='sharedstorage'>Enable Shared Storage support</flag> - <flag name='htools'>Enable htools support</flag> <flag name='haskell-daemons'>Build haskell daemons instead of python</flag> + <flag name='htools'>Enable htools support</flag> + <flag name='kvm'>Enable KVM support</flag> + <flag name='lxc'>Enable Linux Countainers support</flag> + <flag name='multiple-users'>Enable support for running VMs as different users.</flag> + <flag name='monitoring'>Enable the ganeti monitoring daemon</flag> <flag name='rbd'>Enable rados block device support via sys-cluster/ceph</flag> + <flag name='sharedstorage'>Enable Shared Storage support</flag> + <flag name='xen'>Enable Xen support</flag> </use> </pkgmetadata> |