Package-Manager: portage-2.2.0_alpha166
RepoMan-Options: --force
This commit is contained in:
Mario Fetka 2013-04-16 20:50:41 +02:00
parent d730a31b8c
commit 6201844ed5
6 changed files with 222 additions and 87 deletions

View File

@ -1,7 +1,13 @@
# ChangeLog for net-misc/opsiconfd # ChangeLog for net-misc/opsiconfd
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
# $Header: $ # $Header: $
*opsiconfd-4.0.3.1 (16 Apr 2013)
16 Apr 2013; Mario Fetka <mario.fetka@gmail.com> +files/opsiconfd.confd,
+files/opsiconfd.initd, +opsiconfd-4.0.3.1.ebuild, -opsiconfd-4.0.2.4.ebuild:
Bump
*opsiconfd-4.0.2.4 (12 Nov 2012) *opsiconfd-4.0.2.4 (12 Nov 2012)
12 Nov 2012; Mario Fetka <mario.fetka@gmail.com> -opsiconfd-4.0.2.1.ebuild, 12 Nov 2012; Mario Fetka <mario.fetka@gmail.com> -opsiconfd-4.0.2.1.ebuild,
@ -25,4 +31,3 @@
04 Feb 2012; Mario Fetka <mario.fetka@gmail.com> +opsiconfd-4.0.1.9.ebuild, 04 Feb 2012; Mario Fetka <mario.fetka@gmail.com> +opsiconfd-4.0.1.9.ebuild,
+metadata.xml: +metadata.xml:
Initial Commit Initial Commit

View File

@ -1,4 +1,6 @@
DIST opsiconfd-4.0.2.4-1.1.src.rpm 57158 SHA256 3fcfaad272ad76c6a560b47578b6ab60c3666bb26fb0fd333f4e56ee5e803bf3 SHA512 426063ec0036507d8af86710c4e9f1bcaccc58c4ce1be46731a1e60d8f8514a32093c419dac6d5e2e43aeadd8261c1c633d3192dcaf78df135ff3057f7ab1b76 WHIRLPOOL 06aa9f6e310e632d5476c1c4fa71d6fd0db7a5511488769db70cbad4ec723cfea4a770ca0e5868e672bbbd6360e2727fc98482cb1ea1fa9c762e81b54d0f6c5e AUX opsiconfd.confd 187 SHA256 3a4bcaeddd988c98fa0f443e47236cc0bf3cfded3f2a90edbdea51045561ebc4 SHA512 ae1481c23ef1c86a91c39f8f23803f1d0b01fc53ac99a45fb26c9e6b1a7d2155e23d1557d9e868984039072b04a2a3f2b8c8af34433086e815d6a19ffbb7d382 WHIRLPOOL b04386d78ccc5e630cbbefb460d33ca05364da6c1c0a57c4c18d0c92f9d684ccf7b11598d741ad87d6b55731b956be36beed67214d5ad4ac184625526b35c73d
EBUILD opsiconfd-4.0.2.4.ebuild 2109 SHA256 d71ebeac0117bb427648a2f6b3d4d4275684512e900d62d3cb1d903b0d46e09b SHA512 ccef4d7dd78bb59fb00b1db725158d26ed9d19985da7369adb7512c5cabc1215d00e854b5247d349e86f644412478e90e5d9a5c837207b0db32f5fa9bfb4c3f4 WHIRLPOOL d89db941470a1a2b4aaa1a12072509cfae33755a61fc31e7418c1476fb7b1f75ed3d1f68cec1e24632d79c3c46d64f804a87803060a9240d4b7d44fa8b28e95b AUX opsiconfd.initd 1867 SHA256 2a875ab6928b19a8bef8a448de1daafe31051c652d8850215e0d27fd075e4415 SHA512 c5f86506e583ce5d0a14fb129b6352191b9a869729f87b705afc7c8989efdf84fdec8b3f08622992f4e60231f042c171566954c3b6d8cdf86bf9030ce50c1920 WHIRLPOOL b944bd0adc74f075f0e93b58ee4dc5683a8e809b82d70a73aa1a79029ffb4c96fb7bb173b1193e8a1057cc08663eba51094f60dd3667673f75370631b049822e
MISC ChangeLog 716 SHA256 68c514969a9f144dc42b17bbb7553af459881a864658ca4987f43a2cca83edc9 SHA512 ff1c9c79a53904d6b7a0f2ab28c191c8f06d824d6358e2972b8d850193f872d54ba118de2a008370a38a794ba12dc187c5627dd04ea98e023c5f22d042fca4f5 WHIRLPOOL 85d68ec62ad7edce73edc1759255bce7fb8d382f40069953d29c43da0d6907a23ac6f2f7a9eac2cf22b93a5bc6f5d1e04f3ec5edcfaa58150e25c2644346142c DIST opsiconfd-4.0.3.1-1.1.src.rpm 57657 SHA256 73c56982d226f834a0373ce42b25ee268c877221ee47751903aa927407ead5dc SHA512 e8b33616aa134b8db3d1f4d3bad91d305355bfca8183f07ef28ab229087f2232cf642ada208fcb74ee8433dfcd8e5e20cc15d8ab01983d768ba626c6b47f3374 WHIRLPOOL 0cf1e6e0610368ab85448e17216d28c173492f47355e67fc9b43431cb0dc6265e739ccbf10ccaebd828ad4c9dadda5000c2296f69d41c3ecc78cc61b8ed21b7c
EBUILD opsiconfd-4.0.3.1.ebuild 4015 SHA256 cc0bb2f042335ea875558195d7c1ad2b3150e1ed6596fd5e9f998bed014a3492 SHA512 88b7df09d7e7550b458640d4ad9ca0c1445cfa7e0e776e626d4367e1fe1a64b8d57f58f19a1935130fa261f5eb244ad847a61ff186da82dbab6fabd9ec6f62c0 WHIRLPOOL f656ae3b19076195ec5a31a4ce13a85b631ff8c3b6b49525e744e841cca9230a744a34ec4bdf59b1511a25aee1e21f81128510e01c22df4e29e9a5b887405bda
MISC ChangeLog 912 SHA256 005e8209e38d50d15c920b0b9f1d57f27232b38f390f534679f8e6fcaa00fcf3 SHA512 3ec845664c03d1eb687e7069d3e906e5af044befa97bc1510316138b0e7dcb4cba07811a3bea8b09745b5f3fa8447e237f56f93edd25c7aac51531cf2d2910b8 WHIRLPOOL 005475508401324cc036d18746d13860362921b8e8873c52b764a83d0a66494618bab9e33477bc2c163d46b77d064e4b519488df164e49a49b162f117da85326
MISC metadata.xml 226 SHA256 a9d3f7df2362a9a7ddcbe05c5d97d726eeb4bab135b21643508149a08bf6a2b2 SHA512 5912920d8f6e9ee5126fb0aaa5717a562feb009cc59b759c6a6eaa909900b19e95e51e3aa7f32fdf2e77073b19878830b97947148e3adeff3b49e7555cfe29e9 WHIRLPOOL c07e2ddb648893f1e9c422e07b0b73a6d0f7e1c9501200b6fcc9d25fe68c3b05fe4f3523e6844067eeca6969973a44004e1ba8a6fa725591a1916648bd2d4834 MISC metadata.xml 226 SHA256 a9d3f7df2362a9a7ddcbe05c5d97d726eeb4bab135b21643508149a08bf6a2b2 SHA512 5912920d8f6e9ee5126fb0aaa5717a562feb009cc59b759c6a6eaa909900b19e95e51e3aa7f32fdf2e77073b19878830b97947148e3adeff3b49e7555cfe29e9 WHIRLPOOL c07e2ddb648893f1e9c422e07b0b73a6d0f7e1c9501200b6fcc9d25fe68c3b05fe4f3523e6844067eeca6969973a44004e1ba8a6fa725591a1916648bd2d4834

View File

@ -0,0 +1,7 @@
# /etc/conf.d/opsiconfd: config file for /etc/init.d/opsiconfd
# Options to pass to the opsiconfd daemon.
# See the opsiconfd man page for more info.
OPSICONFD_OPTIONS=""
START_GUARD=1

View File

@ -0,0 +1,74 @@
#!/sbin/runscript
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
OPSICONFDCONFIG=/etc/opsi/opsiconfd.conf
OPSICONFDPROGRAM=/usr/bin/opsiconfd
[ -x $OPSICONFDPROGRAM ] || exit 0
OPSICONFDCONFIG_OPT=""
[ ! -z $OPSICONFDCONFIG -a -f $OPSICONFDCONFIG ] && OPSICONFDCONFIG_OPT="-c $OPSICONFDCONFIG"
USER=opsiconfd
LOGDIR=/var/log/opsi/opsiconfd
PIDDIR=/var/run/opsiconfd
LIBDIR=/var/lib/opsiconfd
MBUSDIR=/var/run/opsi-message-bus
RRDDIR=${LIBDIR}/rrd
PIDFILE=${PIDDIR}/opsiconfd.pid
GUARD_BIN=/usr/bin/opsiconfd-guard
GLOBAL_CONF=/etc/opsi/global.conf
depend() {
need net
}
start() {
# Make sure files are writable
[ ! -e ${LOGDIR} ] && mkdir -p ${LOGDIR}
chown -R ${USER} ${LOGDIR}
[ ! -e ${LIBDIR} ] && mkdir -p ${LIBDIR}
chown -R ${USER} ${LIBDIR}
[ ! -e ${RRDDIR} ] && mkdir -p ${RRDDIR}
chown -R ${USER} ${RRDDIR}
[ ! -e ${PIDDIR} ] && mkdir -p ${PIDDIR}
chown -R ${USER} ${PIDDIR}
[ ! -e ${MBUSDIR} ] && mkdir -p ${MBUSDIR}
chown -R ${USER} ${MBUSDIR}
if [ "$START_GUARD" = "1" ]; then
ebegin "Starting opsi guard"
start-stop-daemon --start \
--exec ${GUARD_BIN} -- ${OPSIGUARD_OPTIONS}
eend $?
fi
ebegin "Starting opsi config service"
start-stop-daemon --start \
--user ${USER} \
--pidfile ${PIDFILE} \
--exec ${OPSICONFDPROGRAM} -- -D ${OPSICONFDCONFIG_OPT} ${OPSICONFD_OPTIONS}
eend $?
}
stop() {
if [ "$START_GUARD" = "1" ]; then
ebegin "Stopping opsi guard"
# Kill opsiconfd-guard
killall $(basename $GUARD_BIN) >/dev/null 2>/dev/null || true
#start-stop-daemon --stop \
# --name $(basename ${GUARD_BIN}) \
# --exec ${GUARD_BIN} -- ${OPSIGUARD_OPTIONS}
eend $?
fi
ebegin "Stopping opsi config service"
start-stop-daemon --stop \
--pidfile ${PIDFILE} \
--exec ${OPSICONFDPROGRAM} -- ${OPSICONFDCONFIG_OPT}
eend $?
}

View File

@ -1,82 +0,0 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/www-apps/trac/trac-0.12.2-r1.ebuild,v 1.1 2011/12/31 20:17:50 idl0r Exp $
EAPI="2"
PYTHON_DEPEND="2"
SUPPORT_PYTHON_ABIS="1"
RPM_VER="1.1"
inherit distutils eutils rpm
DESCRIPTION="opsi configuration service"
HOMEPAGE="http://opsi.org"
LICENSE="GPL-2"
SRC_URI="http://download.opensuse.org/repositories/home:/uibmz:/opsi:/opsi40/openSUSE_12.1/src/${P}-${RPM_VER}.src.rpm"
IUSE=""
KEYWORDS="~amd64 ~arm ~x86"
# doing so because tools, python packages... overlap
SLOT="0"
RDEPEND="dev-python/python-opsi
dev-python/twisted
net-analyzer/rrdtool[python]
net-dns/avahi[python]"
DEPEND="${RDEPEND}
dev-python/setuptools
dev-libs/openssl
dev-python/dbus-python
sys-process/procps"
RESTRICT_PYTHON_ABIS="3.*"
pkg_setup() {
python_pkg_setup
enewgroup pcpatch 992
enewuser opsiconfd 993 -1 /var/lib/opsi pcpatch
enewgroup opsiadmin
}
# the default src_compile just calls setup.py build
# currently, this switches i18n catalog compilation based on presence of Babel
src_install() {
distutils_src_install
# project environments might go in here
# keepdir /var/lib/trac
# Use this as the egg-cache for tracd
# dodir /var/lib/trac/egg-cache
# keepdir /var/lib/trac/egg-cache
# fowners tracd:tracd /var/lib/trac/egg-cache
# documentation
# cp -r contrib "${D}"/usr/share/doc/${P}/
# tracd init script
# newconfd "${FILESDIR}"/tracd.confd tracd
# newinitd "${FILESDIR}"/tracd.initd tracd
}
pkg_postinst() {
distutils_pkg_postinst
#openssl req -x509 -newkey rsa:2048 -batch -nodes\
#-config ${INTRINsec_HOME}/${PN}/conf/openssl.cnf\
#-out ${INTRINsec_HOME}/${PN}/conf/vulture.crt\
#-keyout ${INTRINsec_HOME}/${PN}/conf/vulture.key
#einfo "Vulture is installed. You can now type the following :"
#einfo "echo \"apache ALL=NOPASSWD:/usr/sbin/apache2\" >> /etc/sudoers"
chmod 600 /etc/opsi/opsiconfd.pem
chown opsiconfd:opsiadmin /etc/opsi/opsiconfd.pem || true
chmod 750 /var/log/opsi/opsiconfd
chown -R opsiconfd:pcpatch /var/log/opsi/opsiconfd
}

View File

@ -0,0 +1,129 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI="2"
PYTHON_DEPEND="2"
SUPPORT_PYTHON_ABIS="1"
RESTRICT_PYTHON_ABIS="3.*"
RPM_VER="1.1"
inherit distutils eutils rpm
DESCRIPTION="opsi configuration service"
HOMEPAGE="http://opsi.org"
LICENSE="GPL-2"
SRC_URI="http://download.opensuse.org/repositories/home:/uibmz:/opsi:/opsi40/openSUSE_12.2/src/${P}-${RPM_VER}.src.rpm"
IUSE=""
KEYWORDS="~amd64 ~arm ~x86"
# doing so because tools, python packages... overlap
SLOT="0"
#BuildRequires: python-devel python-setuptools openssl dbus-1-python procps
#Requires: python-opsi >= 4.0.1.37 openssl python-twisted dbus-1-python psmisc procps
#Requires: python-opsi >= 4.0.1.37 openssl python-twisted dbus-1-python psmisc procps python-rrdtool
#BuildRequires: python-rrdtool python-opsi >= 4.0.1.32
#Requires: python-avahi
#BuildRequires: python-rrdtool
RDEPEND="dev-python/python-opsi
dev-python/twisted
net-analyzer/rrdtool[python]
net-dns/avahi[python]"
DEPEND="${RDEPEND}
dev-python/setuptools
dev-libs/openssl
dev-python/dbus-python
sys-process/procps"
src_install() {
distutils_src_install
keepdir /var/log/opsi/opsiconfd
keepdir /var/lib/opsiconfd/rrd
keepdir /var/lib/opsi/config/depots
newinitd "${FILESDIR}"/opsiconfd.initd opsiconfd
newconfd "${FILESDIR}"/opsiconfd.confd opsiconfd
}
pkg_postinst() {
distutils_pkg_postinst
fileadmingroup=$(grep "fileadmingroup" /etc/opsi/opsi.conf | cut -d "=" -f 2 | sed 's/\s*//g')
if [ -z "$fileadmingroup" ]; then
fileadmingroup=pcpatch
fi
if [ $fileadmingroup != pcpatch -a -z "$(getent group $fileadmingroup)" ]; then
groupmod -n $fileadmingroup pcpatch
else
if [ -z "$(getent group $fileadmingroup)" ]; then
groupadd $fileadmingroup
fi
fi
if [ -z "`getent passwd opsiconfd`" ]; then
useradd -r -G pcpatch -d /var/lib/opsi -s /bin/bash opsiconfd
fi
if [ -z "`getent group opsiadmin`" ]; then
groupadd opsiadmin
fi
groupmod -A opsiconfd shadow 1>/dev/null 2>/dev/null || true
groupmod -A opsiconfd uucp 1>/dev/null 2>/dev/null || true
groupmod -A opsiconfd opsiadmin 1>/dev/null 2>/dev/null || true
if [ ! -e "/etc/opsi/opsiconfd.pem" ]; then
umask 077
cert_country="DE"
cert_state="RP"
cert_locality="Mainz"
cert_organization="uib GmbH"
cert_commonname=`hostname -f`
cert_email="root@$cert_commonname"
echo "RANDFILE = /tmp/opsiconfd.rand" > /tmp/opsiconfd.cnf
echo "" >> /tmp/opsiconfd.cnf
echo "[ req ]" >> /tmp/opsiconfd.cnf
echo "default_bits = 1024" >> /tmp/opsiconfd.cnf
echo "encrypt_key = yes" >> /tmp/opsiconfd.cnf
echo "distinguished_name = req_dn" >> /tmp/opsiconfd.cnf
echo "x509_extensions = cert_type" >> /tmp/opsiconfd.cnf
echo "prompt = no" >> /tmp/opsiconfd.cnf
echo "" >> /tmp/opsiconfd.cnf
echo "[ req_dn ]" >> /tmp/opsiconfd.cnf
echo "C=$cert_country" >> /tmp/opsiconfd.cnf
echo "ST=$cert_state" >> /tmp/opsiconfd.cnf
echo "L=$cert_locality" >> /tmp/opsiconfd.cnf
echo "O=$cert_organization" >> /tmp/opsiconfd.cnf
#echo "OU=$cert_unit" >> /tmp/opsiconfd.cnf
echo "CN=$cert_commonname" >> /tmp/opsiconfd.cnf
echo "emailAddress=$cert_email" >> /tmp/opsiconfd.cnf
echo "" >> /tmp/opsiconfd.cnf
echo "[ cert_type ]" >> /tmp/opsiconfd.cnf
echo "nsCertType = server" >> /tmp/opsiconfd.cnf
dd if=/dev/urandom of=/tmp/opsiconfd.rand count=1 2>/dev/null
openssl req -new -x509 -days 1000 -nodes \
-config /tmp/opsiconfd.cnf -out /etc/opsi/opsiconfd.pem -keyout /etc/opsi/opsiconfd.pem
openssl gendh -rand /tmp/opsiconfd.rand 512 >>/etc/opsi/opsiconfd.pem
openssl x509 -subject -dates -fingerprint -noout -in /etc/opsi/opsiconfd.pem
rm -f /tmp/opsiconfd.rand /tmp/opsiconfd.cnf
fi
chmod 600 /etc/opsi/opsiconfd.pem
chown opsiconfd:opsiadmin /etc/opsi/opsiconfd.pem || true
chmod 750 /var/log/opsi/opsiconfd
chown -R opsiconfd:$fileadmingroup /var/log/opsi/opsiconfd
}