diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /dev-python/carbon | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.xz |
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 'dev-python/carbon')
-rw-r--r-- | dev-python/carbon/Manifest | 2 | ||||
-rw-r--r-- | dev-python/carbon/carbon-0.9.12-r1.ebuild | 65 | ||||
-rw-r--r-- | dev-python/carbon/carbon-0.9.13.ebuild | 65 | ||||
-rw-r--r-- | dev-python/carbon/files/carbon-0.9.12-no-data-files.patch | 24 | ||||
-rw-r--r-- | dev-python/carbon/files/carbon.confd | 5 | ||||
-rw-r--r-- | dev-python/carbon/files/carbon.initd | 52 | ||||
-rw-r--r-- | dev-python/carbon/files/no-data-files.patch | 26 | ||||
-rw-r--r-- | dev-python/carbon/metadata.xml | 8 |
8 files changed, 247 insertions, 0 deletions
diff --git a/dev-python/carbon/Manifest b/dev-python/carbon/Manifest new file mode 100644 index 00000000000..f18c232deac --- /dev/null +++ b/dev-python/carbon/Manifest @@ -0,0 +1,2 @@ +DIST carbon-0.9.12.tar.gz 47450 SHA256 df4b521a449b888fc901d11abffc9e7eb070a8670e341caa0e13ab8f3029cddf SHA512 060b3d20cf2bd95be22fba30a24591361c772edaaaa99117616f4a01a31eab9395d84c5eb835408fac2c1bc36b70950e260d56456879489a9ee3248c6c4e3f33 WHIRLPOOL c6021492dc5ed3c9c4cefe173b1e0592b18e6c2d49e48cd74059c4d3822ea0b2cf253bedc9a67f7fa37dd8944e06835a1da959300e3c6e0f1759622b19b0c61e +DIST carbon-0.9.13.tar.gz 47509 SHA256 75aecd8114435430e06803ebaf1e9cac81f58fb231fc93d8904d667d971ae6cd SHA512 89c843ac67ed4b68c28273459e5a96594851e5d2694fdefdfb71cebcdc6555d4aac8c45c1c6d2ca61a15405bac7ba3d27836470fe152d5d7a4936bb2d00e6776 WHIRLPOOL 40000d912f3881dc4f197e1290d3e0fd092ec23bc6574a97fa31d0ffa77fa651abc4d4da529e45d88d74ea763f18cde20daf5fd70549d6afd38f4c5b88d1becb diff --git a/dev-python/carbon/carbon-0.9.12-r1.ebuild b/dev-python/carbon/carbon-0.9.12-r1.ebuild new file mode 100644 index 00000000000..394ffe7411d --- /dev/null +++ b/dev-python/carbon/carbon-0.9.12-r1.ebuild @@ -0,0 +1,65 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +PYTHON_COMPAT=( python2_7 ) + +inherit distutils-r1 + +DESCRIPTION="Backend data caching and persistence daemon for Graphite" +HOMEPAGE="http://graphite.wikidot.com/" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +SLOT="0" +LICENSE="Apache-2.0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +DEPEND="" +RDEPEND="${DEPEND} + ~dev-python/twisted-core-12.3.0[${PYTHON_USEDEP}] + dev-python/whisper[${PYTHON_USEDEP}] + dev-python/txAMQP[${PYTHON_USEDEP}]" + +PATCHES=( + # Do not install the configuration and data files. We install them + # somewhere sensible by hand. + "${FILESDIR}"/${P}-no-data-files.patch + ) + +python_prepare_all() { + # This sets prefix to /opt/graphite. We want FHS-style paths instead. + rm setup.cfg || die + distutils-r1_python_prepare_all +} + +python_install_all() { + distutils-r1_python_install_all + + insinto /etc/carbon + doins conf/* + + dodir /var/log/carbon /var/lib/carbon/{whisper,lists,rrd} + + newinitd "${FILESDIR}"/carbon.initd carbon-cache + newinitd "${FILESDIR}"/carbon.initd carbon-relay + newinitd "${FILESDIR}"/carbon.initd carbon-aggregator + + newconfd "${FILESDIR}"/carbon.confd carbon-cache + newconfd "${FILESDIR}"/carbon.confd carbon-relay + newconfd "${FILESDIR}"/carbon.confd carbon-aggregator +} + +pkg_postinst() { + einfo 'This ebuild installs carbon into FHS-style paths.' + einfo 'You will probably have to set GRAPHITE_CONF_DIR to /etc/carbon' + einfo 'and GRAPHITE_STORAGE_DIR to /var/lib/carbon to make use of this' + einfo '(see /etc/carbon/carbon.conf.example).' + einfo ' ' + einfo 'OpenRC init script supports multiple instances !' + einfo 'Example to run an instance b of carbon-cache :' + einfo ' ln -s /etc/init.d/carbon-cache /etc/init.d/carbon-cache.b' + einfo ' cp /etc/conf.d/carbon-cache /etc/conf.d/carbon-cache.b' +} diff --git a/dev-python/carbon/carbon-0.9.13.ebuild b/dev-python/carbon/carbon-0.9.13.ebuild new file mode 100644 index 00000000000..4b7ed80fb33 --- /dev/null +++ b/dev-python/carbon/carbon-0.9.13.ebuild @@ -0,0 +1,65 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +PYTHON_COMPAT=( python2_7 ) + +inherit distutils-r1 + +DESCRIPTION="Backend data caching and persistence daemon for Graphite" +HOMEPAGE="http://graphite.wikidot.com/" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +SLOT="0" +LICENSE="Apache-2.0" +KEYWORDS="amd64 x86" +IUSE="" + +DEPEND="" +RDEPEND=" + dev-python/twisted-core[${PYTHON_USEDEP}] + dev-python/whisper[${PYTHON_USEDEP}] + dev-python/txAMQP[${PYTHON_USEDEP}]" + +PATCHES=( + # Do not install the configuration and data files. We install them + # somewhere sensible by hand. + "${FILESDIR}"/${PN}-0.9.12-no-data-files.patch + ) + +python_prepare_all() { + # This sets prefix to /opt/graphite. We want FHS-style paths instead. + rm setup.cfg || die + distutils-r1_python_prepare_all +} + +python_install_all() { + distutils-r1_python_install_all + + insinto /etc/carbon + doins conf/* + + dodir /var/log/carbon /var/lib/carbon/{whisper,lists,rrd} + + newinitd "${FILESDIR}"/carbon.initd carbon-cache + newinitd "${FILESDIR}"/carbon.initd carbon-relay + newinitd "${FILESDIR}"/carbon.initd carbon-aggregator + + newconfd "${FILESDIR}"/carbon.confd carbon-cache + newconfd "${FILESDIR}"/carbon.confd carbon-relay + newconfd "${FILESDIR}"/carbon.confd carbon-aggregator +} + +pkg_postinst() { + einfo 'This ebuild installs carbon into FHS-style paths.' + einfo 'You will probably have to set GRAPHITE_CONF_DIR to /etc/carbon' + einfo 'and GRAPHITE_STORAGE_DIR to /var/lib/carbon to make use of this' + einfo '(see /etc/carbon/carbon.conf.example).' + einfo ' ' + einfo 'OpenRC init script supports multiple instances !' + einfo 'Example to run an instance b of carbon-cache :' + einfo ' ln -s /etc/init.d/carbon-cache /etc/init.d/carbon-cache.b' + einfo ' cp /etc/conf.d/carbon-cache /etc/conf.d/carbon-cache.b' +} diff --git a/dev-python/carbon/files/carbon-0.9.12-no-data-files.patch b/dev-python/carbon/files/carbon-0.9.12-no-data-files.patch new file mode 100644 index 00000000000..129c7189f3b --- /dev/null +++ b/dev-python/carbon/files/carbon-0.9.12-no-data-files.patch @@ -0,0 +1,24 @@ +diff -ur carbon-0.9.12.orig/setup.py carbon-0.9.12/setup.py +--- /setup.py 2013-08-22 00:53:16.000000000 +0800 ++++ /setup.py 2014-01-26 11:20:59.705864697 +0800 +@@ -13,12 +13,6 @@ + setup_kwargs = dict() + + +-storage_dirs = [ ('storage/whisper',[]), ('storage/lists',[]), +- ('storage/log',[]), ('storage/rrd',[]) ] +-conf_files = [ ('conf', glob('conf/*.example')) ] +- +-install_files = storage_dirs + conf_files +- + # If we are building on RedHat, let's use the redhat init scripts. + if platform.dist()[0] == 'redhat': + init_scripts = [ ('/etc/init.d', ['distro/redhat/init.d/carbon-cache', +@@ -39,7 +33,6 @@ + package_dir={'' : 'lib'}, + scripts=glob('bin/*'), + package_data={ 'carbon' : ['*.xml'] }, +- data_files=install_files, + install_requires=['twisted', 'txamqp'], + **setup_kwargs + ) diff --git a/dev-python/carbon/files/carbon.confd b/dev-python/carbon/files/carbon.confd new file mode 100644 index 00000000000..b1875e13467 --- /dev/null +++ b/dev-python/carbon/files/carbon.confd @@ -0,0 +1,5 @@ +# Use the given config file +CARBON_CONFIG="/etc/carbon/carbon.conf" + +# Add extra parameters +CARBON_EXTRA_PARAMETERS="" diff --git a/dev-python/carbon/files/carbon.initd b/dev-python/carbon/files/carbon.initd new file mode 100644 index 00000000000..6fd12c60e78 --- /dev/null +++ b/dev-python/carbon/files/carbon.initd @@ -0,0 +1,52 @@ +#!/sbin/runscript +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +export GRAPHITE_CONF_DIR=/etc/carbon +export GRAPHITE_STORAGE_DIR=/var/lib/carbon + +INSTANCE=${SVCNAME/#*.} +if [ "${INSTANCE}" == "${SVCNAME}" ]; then + INSTANCE="a" +fi + +PIDFILE="/var/run/${SVCNAME}.pid" +PROGRAMNAME=${SVCNAME/.*} + +CARBON_CONFIG=${CARBON_CONFIG:-/etc/carbon/carbon.conf} + +depend() { + use net +} + + +start_pre() { + if [ ! -f ${CARBON_CONFIG} ] ; then + eend "Missing ${CARBON_CONFIG}" + fi + case "${PROGRAMNAME}" in + "carbon-relay" ) + [ -f /etc/carbon/relay-rules.conf ] || eend "Missing relay-rules.conf" + ;; + "carbon-aggregator" ) + [ -f /etc/carbon/aggregation-rules.conf ] || eend "Missing missing aggregation-rules.conf" + ;; + esac +} + +start() { + ebegin "Starting ${PROGRAMNAME} instance ${INSTANCE}" + start-stop-daemon --start --exec /usr/bin/${PROGRAMNAME}.py \ + --pidfile ${PIDFILE} \ + -- --pidfile ${PIDFILE} --instance ${INSTANCE} \ + --logdir /var/log/carbon/ --config ${CARBON_CONFIG} start >/dev/null + eend $? "Failed to start ${SVCNAME}" +} + +stop() { + ebegin "Stopping ${PROGRAMNAME} instance ${INSTANCE}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} + eend $? "Failed to stop ${SVCNAME}" +} diff --git a/dev-python/carbon/files/no-data-files.patch b/dev-python/carbon/files/no-data-files.patch new file mode 100644 index 00000000000..7b0c52f3948 --- /dev/null +++ b/dev-python/carbon/files/no-data-files.patch @@ -0,0 +1,26 @@ +Do not install the empty storage dirs and config files to the wrong +location (the ebuild installs them to the right location by hand). + +See Gentoo bug #417221. + +--- setup.py ++++ setup.py +@@ -12,9 +12,6 @@ + setup_kwargs = dict() + + +-storage_dirs = [ ('storage/whisper',[]), ('storage/lists',[]), +- ('storage/log',[]), ('storage/rrd',[]) ] +-conf_files = [ ('conf', glob('conf/*.example')) ] + #XXX Need a way to have these work for bdist_rpm but be left alone for everything else + #init_scripts = [ ('/etc/init.d', ['distro/redhat/init.d/carbon-cache', + # 'distro/redhat/init.d/carbon-relay', +@@ -32,7 +29,6 @@ + package_dir={'' : 'lib'}, + scripts=glob('bin/*'), + package_data={ 'carbon' : ['*.xml'] }, +- data_files=storage_dirs + conf_files, # + init_scripts, + install_requires=['twisted', 'txamqp'], + **setup_kwargs + ) + diff --git a/dev-python/carbon/metadata.xml b/dev-python/carbon/metadata.xml new file mode 100644 index 00000000000..42a6c423cb5 --- /dev/null +++ b/dev-python/carbon/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>python</herd> + <upstream> + <remote-id type="pypi">carbon</remote-id> + </upstream> +</pkgmetadata> |