summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sys-cluster/vzctl
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sys-cluster/vzctl')
-rw-r--r--sys-cluster/vzctl/Manifest2
-rw-r--r--sys-cluster/vzctl/files/vzctl-initscript-paths.patch142
-rw-r--r--sys-cluster/vzctl/files/vzctl-initscript-typo-patch-4.8.patch32
-rw-r--r--sys-cluster/vzctl/metadata.xml20
-rw-r--r--sys-cluster/vzctl/vzctl-4.9.1.ebuild85
-rw-r--r--sys-cluster/vzctl/vzctl-4.9.2.ebuild86
6 files changed, 367 insertions, 0 deletions
diff --git a/sys-cluster/vzctl/Manifest b/sys-cluster/vzctl/Manifest
new file mode 100644
index 000000000000..5265376492a1
--- /dev/null
+++ b/sys-cluster/vzctl/Manifest
@@ -0,0 +1,2 @@
+DIST vzctl-4.9.1.tar.bz2 517940 SHA256 b15f4b4eacd88d2a5e745f556dfe6ae079a77c0d3f0fa818674bc98715ad7d72 SHA512 998882a1f628104a9e0c6a598ee84046fb03da03b7b2ce703396659cf7d7bd0bb67bf1590596e5e43ff1223ef23078fb7cab2228e768e79d3c3136b1ba418e50 WHIRLPOOL feff55376fa5f470627f7fcbd4e9a0c24e04b8575219d33ffa5eb4a67d79e64682975b89fbf06953d4d88044e1771c9dfef3a5b578914900e5f88f59eb2d3895
+DIST vzctl-4.9.2.tar.bz2 549613 SHA256 a345719d47e8a3f96c5af4c86b58a9677848eee6f4777403b447eff2c9320cae SHA512 c2ab45eb8f8f80c8b044f652c68c1c816b3df85f3aca5fe33b385dea4b6addeb8e6ebe6232342454efc4c683e8433149828dffdbcb181af6bfcb68d8b5a86ef1 WHIRLPOOL 42919c1096133250787996071f1d16e0d6bce542760c58a4d6af019960b6db7df4636d0735f21ffda95032fbabb4cf6709da532bee96e9e7775bf665049cbc46
diff --git a/sys-cluster/vzctl/files/vzctl-initscript-paths.patch b/sys-cluster/vzctl/files/vzctl-initscript-paths.patch
new file mode 100644
index 000000000000..8fc0b12009b4
--- /dev/null
+++ b/sys-cluster/vzctl/files/vzctl-initscript-paths.patch
@@ -0,0 +1,142 @@
+From: Kir Kolyshkin <kir@openvz.org>
+Date: Thu, 3 Jan 2013 19:37:00 +0000 (-0800)
+Subject: init.d/vz-gentoo: don't call tools by absolute path
+X-Git-Url: http://git.openvz.org/?p=vzctl;a=commitdiff_plain;h=2fc34ffb5f5e;hp=9a4a85397f7dd99e2c4059de7fb6ef5d750242c5
+
+init.d/vz-gentoo: don't call tools by absolute path
+
+Apparently in recent Gentoo the ip tool was moved from /sbin to /bin,
+so this initscript stopped working.
+
+Apparently runscript makes sure all the needed directories are in PATH
+(I have tested with runscript from baselayout-1.12.11.1, pretty old one)
+so we can just drop the /sbin/ prefix.
+
+While at it, do it not only for ip, but also for modprobe and sysctl.
+
+http://bugzilla.openvz.org/2477
+https://bugs.gentoo.org/show_bug.cgi?id=444201
+
+Reported-by: Andrei Vinogradov <spamslepnoga@inbox.ru>
+Reported-by: Joakim <moonwalker@astro.nu>
+Signed-off-by: Kir Kolyshkin <kir@openvz.org>
+---
+
+diff --git a/etc/init.d/vz-gentoo.in b/etc/init.d/vz-gentoo.in
+index 2dd2186..51231bc 100755
+--- a/etc/init.d/vz-gentoo.in
++++ b/etc/init.d/vz-gentoo.in
+@@ -87,7 +87,7 @@ start_net() {
+
+ # load necessary modules
+ for mod in ${NET_MODULES}; do
+- /sbin/modprobe ${mod} 2>/dev/null
++ modprobe ${mod} 2>/dev/null
+ done
+
+ if [ ! -f ${VZVEINFO} ]; then
+@@ -95,22 +95,22 @@ start_net() {
+ fi
+
+ # we don't operate on a running interface
+- if /sbin/ip addr list | grep -q "venet0:.*UP" 2>/dev/null; then
++ if ip addr list | grep -q "venet0:.*UP" 2>/dev/null; then
+ return 0
+ fi
+
+ # configure the device
+ ebegin "Bringing up interface ${VZDEV}"
+- /sbin/ip link set ${VZDEV} up
++ ip link set ${VZDEV} up
+ eend $?
+
+- /sbin/ip addr add 0.0.0.0/0 dev ${VZDEV}
++ ip addr add 0.0.0.0/0 dev ${VZDEV}
+
+ ebegin "Configuring interface ${VZDEV}"
+- /sbin/sysctl -q -w net.ipv4.conf.${VZDEV}.send_redirects=0
++ sysctl -q -w net.ipv4.conf.${VZDEV}.send_redirects=0
+ eend $?
+
+- if [ "x$(/sbin/sysctl -n -e net.ipv4.ip_forward)" != "x1" ]; then
++ if [ "x$(sysctl -n -e net.ipv4.ip_forward)" != "x1" ]; then
+ ewarn "It looks like you have ip forwarding disabled. To make networking"
+ ewarn "available for containers, please, run sysctl -w net.ipv4.ip_forward=1"
+ fi
+@@ -119,15 +119,15 @@ start_net() {
+ stop_net() {
+ local mod
+
+- if /sbin/ip addr list | grep -q "venet0:.*UP" 2>/dev/null; then
++ if ip addr list | grep -q "venet0:.*UP" 2>/dev/null; then
+ ebegin "Bringing down interface ${VZDEV}"
+- /sbin/ip link set ${VZDEV} down 2>/dev/null
++ ip link set ${VZDEV} down 2>/dev/null
+ eend $?
+ fi
+
+ # remove all modules we probably loaded on start_net
+ for mod in ${NET_MODULES}; do
+- /sbin/modprobe -r ${mod} > /dev/null 2>&1
++ modprobe -r ${mod} > /dev/null 2>&1
+ done
+ }
+
+@@ -146,7 +146,7 @@ start_ve() {
+ # Then sort by bootorder
+ test -n "$velist" && velist=$(vzlist -aH -octid -s-bootorder $velist)
+
+- /sbin/sysctl -q -w net.ipv4.route.src_check=0
++ sysctl -q -w net.ipv4.route.src_check=0
+
+ for veid in ${velist}; do
+ ebegin "Starting CT ${veid}"
+@@ -302,16 +302,16 @@ start() {
+
+ ebegin "Loading OpenVZ modules"
+ for mod in ${IPTABLES_MODULES}; do
+- /sbin/modprobe ${mod} >/dev/null 2>&1
++ modprobe ${mod} >/dev/null 2>&1
+ done
+
+ for mod in ${PRELOAD_MODULES}; do
+- /sbin/modprobe -r ${mod} >/dev/null 2>&1
+- /sbin/modprobe ${mod} >/dev/null 2>&1
++ modprobe -r ${mod} >/dev/null 2>&1
++ modprobe ${mod} >/dev/null 2>&1
+ done
+
+ for mod in ${MODULES}; do
+- /sbin/modprobe ${mod} >/dev/null 2>&1
++ modprobe ${mod} >/dev/null 2>&1
+ rc=$?
+ if [ ${rc} -ne 0 ]; then
+ eend ${rc} "failed to load module ${mod}"
+@@ -320,7 +320,7 @@ start() {
+ done
+
+ for mod in ${MIGRATE_MODULES} ${PLOOP_MODULES}; do
+- /sbin/modprobe ${mod} >/dev/null 2>&1
++ modprobe ${mod} >/dev/null 2>&1
+ done
+ eend
+
+@@ -365,15 +365,15 @@ stop() {
+ stop_net
+
+ for mod in ${MIGRATE_MODULES} ${PLOOP_MODULES}; do
+- /sbin/modprobe -r ${mod} > /dev/null 2>&1
++ modprobe -r ${mod} > /dev/null 2>&1
+ done
+
+ for mod in ${MODULES}; do
+- /sbin/modprobe -r ${mod} > /dev/null 2>&1
++ modprobe -r ${mod} > /dev/null 2>&1
+ done
+
+ for mod in ${PRELOAD_MODULES}; do
+- /sbin/modprobe -r ${mod} > /dev/null 2>&1
++ modprobe -r ${mod} > /dev/null 2>&1
+ done
+
+ # Even if some modules failed to unload (say they were not loaded)
diff --git a/sys-cluster/vzctl/files/vzctl-initscript-typo-patch-4.8.patch b/sys-cluster/vzctl/files/vzctl-initscript-typo-patch-4.8.patch
new file mode 100644
index 000000000000..ee4818f19d27
--- /dev/null
+++ b/sys-cluster/vzctl/files/vzctl-initscript-typo-patch-4.8.patch
@@ -0,0 +1,32 @@
+From: Kir Kolyshkin <kir@openvz.org>
+Date: Tue, 14 Oct 2014 09:22:49 +0000 (-0700)
+Subject: init.d/vz-gentoo: fix a typo
+X-Git-Url: http://git.openvz.org/?p=vzctl;a=commitdiff_plain;h=7dd296400299f13964b2665792fbe1ea89ac6241
+
+init.d/vz-gentoo: fix a typo
+
+As reported in
+
+http://forum.openvz.org/index.php?t=msg&th=12775&S=cec69936a4b7d441bf7f44478dbb6c3c#msg_51690
+
+there's a missing bracket.
+
+This is a fix to commit 8e7fdb5.
+
+Reported-by: Sergey Ya Korshunoff
+Signed-off-by: Kir Kolyshkin <kir@openvz.org>
+---
+
+diff --git a/etc/init.d/vz-gentoo.in b/etc/init.d/vz-gentoo.in
+index d937408..c7b5604 100755
+--- a/etc/init.d/vz-gentoo.in
++++ b/etc/init.d/vz-gentoo.in
+@@ -202,7 +202,7 @@ start_ve() {
+
+ get_parallel()
+ {
+- [ -n "${VE_PARALLEL}" -a "${VE_PARALLEL" != "0" ] && return
++ [ -n "${VE_PARALLEL}" -a "${VE_PARALLEL}" != "0" ] && return
+ VE_PARALLEL=`awk '
+ BEGIN { num=0; }
+ $1 == "processor" { num++; }
diff --git a/sys-cluster/vzctl/metadata.xml b/sys-cluster/vzctl/metadata.xml
new file mode 100644
index 000000000000..95759dca8f2d
--- /dev/null
+++ b/sys-cluster/vzctl/metadata.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>proxy-maintainers</herd>
+ <maintainer>
+ <email>andreis.vinogradovs@gmail.com</email>
+ <name>Andreis Vinogradovs</name>
+ <description>Primary maintainer, assign bugs to him</description>
+ </maintainer>
+ <use>
+ <flag name='ploop'>Add support for ploop devices via <pkg>sys-cluster/ploop</pkg></flag>
+ <flag name='vzmigrate'>Add support for container migration</flag>
+ </use>
+ <upstream>
+ <maintainer status="active">
+ <email>kir@openvz.org</email>
+ <name>Kir Kolyshkin</name>
+ </maintainer>
+ </upstream>
+</pkgmetadata>
diff --git a/sys-cluster/vzctl/vzctl-4.9.1.ebuild b/sys-cluster/vzctl/vzctl-4.9.1.ebuild
new file mode 100644
index 000000000000..29c22c8ea788
--- /dev/null
+++ b/sys-cluster/vzctl/vzctl-4.9.1.ebuild
@@ -0,0 +1,85 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit base bash-completion-r1 eutils toolchain-funcs udev
+
+DESCRIPTION="OpenVZ ConTainers control utility"
+HOMEPAGE="http://openvz.org/"
+SRC_URI="http://download.openvz.org/utils/${PN}/${PV}/src/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ~ppc64 x86 -amd64-fbsd -sparc-fbsd -x86-fbsd"
+IUSE="+ploop +vzmigrate"
+
+RDEPEND="net-firewall/iptables
+ sys-apps/ed
+ >=sys-apps/iproute2-3.3.0
+ >=sys-fs/vzquota-3.1
+ ploop? (
+ >=sys-cluster/ploop-1.13
+ sys-block/parted
+ sys-fs/quota
+ dev-libs/libxml2
+ )
+ >=dev-libs/libcgroup-0.38
+ vzmigrate? (
+ net-misc/openssh
+ net-misc/rsync[xattr,acl]
+ app-arch/tar[xattr,acl]
+ net-misc/bridge-utils
+ virtual/awk
+ )
+ virtual/udev
+ "
+
+DEPEND="${RDEPEND}
+ virtual/pkgconfig
+ "
+
+src_prepare() {
+
+ # Set default OSTEMPLATE on gentoo
+ sed -i -e 's:=redhat-:=gentoo-:' etc/dists/default || die 'sed on etc/dists/default failed'
+ # Set proper udev directory
+ sed -i -e "s:/lib/udev:$(get_udevdir):" src/lib/dev.c || die 'sed on src/lib/dev.c failed'
+}
+
+src_configure() {
+
+ econf \
+ --localstatedir=/var \
+ --enable-udev \
+ --enable-bashcomp \
+ --enable-logrotate \
+ --with-vz \
+ $(use_with ploop) \
+ --with-cgroup
+}
+
+src_install() {
+
+ emake DESTDIR="${D}" udevdir="$(get_udevdir)"/rules.d install install-gentoo
+
+ # install the bash-completion script into the right location
+ rm -rf "${ED}"/etc/bash_completion.d
+ newbashcomp etc/bash_completion.d/vzctl.sh ${PN}
+
+ # We need to keep some dirs
+ keepdir /vz/{dump,lock,root,private,template/cache}
+ keepdir /etc/vz/names /var/lib/vzctl/veip
+}
+
+pkg_postinst() {
+ einfo "This vzctl release required kernel above 2.6.32.92"
+
+ einfo "If you have checkpoint suspend/restore feature in vanilla kernel"
+ einfo "please install "sys-process/criu" "
+ einfo "This is experimental and not stable ( in gentoo ) now"
+
+ einfo "if you have work with .xz compressed template, please install app-arch/xz-utils"
+ einfo "if you have check signature donwloaded template - install gpg "
+}
diff --git a/sys-cluster/vzctl/vzctl-4.9.2.ebuild b/sys-cluster/vzctl/vzctl-4.9.2.ebuild
new file mode 100644
index 000000000000..2ec6e8f0c05a
--- /dev/null
+++ b/sys-cluster/vzctl/vzctl-4.9.2.ebuild
@@ -0,0 +1,86 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit base bash-completion-r1 eutils toolchain-funcs udev
+
+DESCRIPTION="OpenVZ ConTainers control utility"
+HOMEPAGE="http://openvz.org/"
+SRC_URI="http://download.openvz.org/utils/${PN}/${PV}/src/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64 ~x86 -amd64-fbsd -sparc-fbsd -x86-fbsd"
+IUSE="+ploop +vzmigrate"
+
+RDEPEND="net-firewall/iptables
+ sys-apps/ed
+ >=sys-apps/iproute2-3.3.0
+ >=sys-fs/vzquota-3.1
+ ploop? (
+ >=sys-cluster/ploop-1.13
+ sys-block/parted
+ sys-fs/quota
+ dev-libs/libxml2
+ )
+ >=dev-libs/libcgroup-0.38
+ vzmigrate? (
+ net-misc/openssh
+ net-misc/rsync[xattr,acl]
+ app-arch/tar[xattr,acl]
+ net-misc/bridge-utils
+ virtual/awk
+ )
+ virtual/udev
+ sys-apps/attr
+ "
+
+DEPEND="${RDEPEND}
+ virtual/pkgconfig
+ "
+
+src_prepare() {
+
+ # Set default OSTEMPLATE on gentoo
+ sed -i -e 's:=redhat-:=gentoo-:' etc/dists/default || die 'sed on etc/dists/default failed'
+ # Set proper udev directory
+ sed -i -e "s:/lib/udev:$(get_udevdir):" src/lib/dev.c || die 'sed on src/lib/dev.c failed'
+}
+
+src_configure() {
+
+ econf \
+ --localstatedir=/var \
+ --enable-udev \
+ --enable-bashcomp \
+ --enable-logrotate \
+ --with-vz \
+ $(use_with ploop) \
+ --with-cgroup
+}
+
+src_install() {
+
+ emake DESTDIR="${D}" udevdir="$(get_udevdir)"/rules.d install install-gentoo
+
+ # install the bash-completion script into the right location
+ rm -rf "${ED}"/etc/bash_completion.d
+ newbashcomp etc/bash_completion.d/vzctl.sh ${PN}
+
+ # We need to keep some dirs
+ keepdir /vz/{dump,lock,root,private,template/cache}
+ keepdir /etc/vz/names /var/lib/vzctl/veip
+}
+
+pkg_postinst() {
+ einfo "This vzctl release required kernel above 2.6.32.92"
+
+ einfo "If you have checkpoint suspend/restore feature in vanilla kernel"
+ einfo "please install "sys-process/criu" "
+ einfo "This is experimental and not stable ( in gentoo ) now"
+
+ einfo "if you have work with .xz compressed template, please install app-arch/xz-utils"
+ einfo "if you have check signature donwloaded template - install gpg "
+}