summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Jackson <iggy@gentoo.org>2003-11-12 22:01:36 +0000
committerBrian Jackson <iggy@gentoo.org>2003-11-12 22:01:36 +0000
commitda08fd3e40eae2a0a3c419a2c7207b7f9e7d6ff2 (patch)
tree780663c6a5899b9740e822a9ca3691a19db9a3f7 /sys-cluster
parentadd init script, fixes 32906 (diff)
downloadgentoo-2-da08fd3e40eae2a0a3c419a2c7207b7f9e7d6ff2.tar.gz
gentoo-2-da08fd3e40eae2a0a3c419a2c7207b7f9e7d6ff2.tar.bz2
gentoo-2-da08fd3e40eae2a0a3c419a2c7207b7f9e7d6ff2.zip
add init script, fixes 32906
Diffstat (limited to 'sys-cluster')
-rw-r--r--sys-cluster/ipvsadm/ChangeLog7
-rw-r--r--sys-cluster/ipvsadm/Manifest6
-rw-r--r--sys-cluster/ipvsadm/files/ipvsadm-init35
-rw-r--r--sys-cluster/ipvsadm/ipvsadm-1.21.ebuild9
4 files changed, 48 insertions, 9 deletions
diff --git a/sys-cluster/ipvsadm/ChangeLog b/sys-cluster/ipvsadm/ChangeLog
index ed23ab6f7e1d..20b5f070fe86 100644
--- a/sys-cluster/ipvsadm/ChangeLog
+++ b/sys-cluster/ipvsadm/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for sys-cluster/ipvsadm
# Copyright 2000-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/ChangeLog,v 1.4 2003/08/18 23:12:16 iggy Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/ChangeLog,v 1.5 2003/11/12 22:01:27 iggy Exp $
+
+ 12 Nov 2003; Brian Jackson <iggy@gentoo.org> ipvsadm-1.21.ebuild,
+ files/ipvsadm-init:
+ added an init script to fix bug 32906, not bumping the -r yet as I want to get somebody
+ to test it
18 Aug 2003; <iggy@gentoo.org> ipvsadm-1.21.ebuild:
1.21 -> x86
diff --git a/sys-cluster/ipvsadm/Manifest b/sys-cluster/ipvsadm/Manifest
index 6ba110eeeec1..282c34dcfe52 100644
--- a/sys-cluster/ipvsadm/Manifest
+++ b/sys-cluster/ipvsadm/Manifest
@@ -1,5 +1,5 @@
-MD5 f9c194a358797b37488533ef64d48889 ipvsadm-1.21.ebuild 925
-MD5 65fa212409fa4b01dd7dd0b43bf1df60 ChangeLog 693
+MD5 7a61eba73717e411a72587f840debcf9 ipvsadm-1.21.ebuild 947
+MD5 4208e656efb46f4e90971c23637200fc ChangeLog 887
MD5 61203435ed5dc50e2259e1df1322b779 metadata.xml 411
MD5 4701a5d41fbd71b84a132051fba6a024 files/digest-ipvsadm-1.21 63
-MD5 d41d8cd98f00b204e9800998ecf8427e files/ipvsadm-init 0
+MD5 55b06899eaaeda665fec6a32e3584bed files/ipvsadm-init 747
diff --git a/sys-cluster/ipvsadm/files/ipvsadm-init b/sys-cluster/ipvsadm/files/ipvsadm-init
new file mode 100644
index 000000000000..a4f821a384cb
--- /dev/null
+++ b/sys-cluster/ipvsadm/files/ipvsadm-init
@@ -0,0 +1,35 @@
+#!/sbin/runscript
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/files/ipvsadm-init,v 1.1 2003/11/12 22:01:27 iggy Exp $
+
+depend() {
+ need net
+}
+
+checkconfig() {
+ if [ ! -f /var/lib/ipvsadm/rules-save ] ; then
+ eerror "Not starting iptables. First create some rules then run"
+ eerror "/etc/init.d/iptables save"
+ return 1
+ fi
+}
+
+start() {
+ ebegin "Starting ipvsadm"
+ einfo "Clearing previous rules"
+ ipvsadm -C
+ ipvsadm-restore < /var/lib/ipvsadm/rules-save
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping ipvsadm"
+ eend $?
+}
+
+save() {
+ ebegin "Saving ipvsadm state"
+ ipvsadm-save > /var/lib/ipvsadm/rules-save
+ eend $?
+}
diff --git a/sys-cluster/ipvsadm/ipvsadm-1.21.ebuild b/sys-cluster/ipvsadm/ipvsadm-1.21.ebuild
index 46815d44c0de..324490af0443 100644
--- a/sys-cluster/ipvsadm/ipvsadm-1.21.ebuild
+++ b/sys-cluster/ipvsadm/ipvsadm-1.21.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/ipvsadm-1.21.ebuild,v 1.4 2003/09/06 22:05:25 msterret Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/ipvsadm-1.21.ebuild,v 1.5 2003/11/12 22:01:27 iggy Exp $
DESCRIPTION="ipvsadm is a utility to administer the IP virtual server services offered by the Linux kernel with IP virtual server support."
@@ -21,7 +21,6 @@ src_compile() {
}
src_install() {
-
into /
dosbin ipvsadm
dosbin ipvsadm-save
@@ -32,8 +31,8 @@ src_install() {
doman ipvsadm-restore.8
exeinto /etc/init.d
- doexe ipvsadm
-
- einfo ""
+ newbin ${FILESDIR}/ipvsadm-init ipvsadm
+ keepdir /var/lib/ipvsadm
+ einfo "You will need a kernel that has ipvs patches to use LVS"
}