summaryrefslogtreecommitdiff
path: root/dev-util/buildbot-slave
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-util/buildbot-slave
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-util/buildbot-slave')
-rw-r--r--dev-util/buildbot-slave/Manifest6
-rw-r--r--dev-util/buildbot-slave/buildbot-slave-0.8.12.ebuild53
-rw-r--r--dev-util/buildbot-slave/files/buildslave.confd9
-rw-r--r--dev-util/buildbot-slave/files/buildslave.initd48
-rw-r--r--dev-util/buildbot-slave/files/buildslave.service15
-rw-r--r--dev-util/buildbot-slave/metadata.xml12
6 files changed, 143 insertions, 0 deletions
diff --git a/dev-util/buildbot-slave/Manifest b/dev-util/buildbot-slave/Manifest
new file mode 100644
index 000000000000..e50f3d398ef7
--- /dev/null
+++ b/dev-util/buildbot-slave/Manifest
@@ -0,0 +1,6 @@
+AUX buildslave.confd 217 BLAKE2B bd752869bc07ad6636b0035ad8f030536abbd9f703a7180e3370e19e09ca41fbd2145d1be48125cac42a06ab1a748612dc5fefebfce23940b28eefbdb015a366 SHA512 54fc03a82cebf874c18d1bd739a6640677cfcd540b47a9929e6f5d63a83bd64bee615b033a72b49ab5fa3da69b16ff657805392ab0a68e0d33e48581fc8bb017
+AUX buildslave.initd 1140 BLAKE2B 45de77ef9400a19b98ebac2ebd7f438354466ef4a2fce407e9d57f0cef6f081683a79d7c5651c1dd14ffbc3e834e980316361ec3a2ec1c29bad8d86bd259092d SHA512 217a9e3f774bcc7e7773d6e3047dbbabe196d168f814485ae54d1a94b330616fd80ad82bfa67c9b6185c39b780eae7a71776e727810ff4df337baca44d5fdbda
+AUX buildslave.service 386 BLAKE2B e50acd31037a91f439330f09e74321e7b8eff67711357c28d661b124fbc36e434a1707629d4ffe151dbf53a7a5600004c3928b511c0aeda672be66e9e492fe18 SHA512 53d9ac95006fb4e43e0bfa82c935e17c577cd292c8fea373247e4cd9bb21843f2f82971ffd37f50aa16fe258139c22adbe24570e3017fa529f2258a1d395d8dd
+DIST buildbot-slave-0.8.12.tar.gz 118339 BLAKE2B e516a8fd212d92e1cb1ed9bc11d70aa4baaea70fd1aa7f4fa239ed1160da51b96391d252643a13a72786d0b676e0e1780d31f998da7b3f90f1b73b32adb6b6c2 SHA512 74f7f9ffab946000a5d31ae28140698ca259ba5b75815ed839d51fa5d9f702e998b61a716b66aab7946b6143d329244f2403d9b98cbbfc70223b691dcb70f0bc
+EBUILD buildbot-slave-0.8.12.ebuild 1564 BLAKE2B 17ac47bee796bc8f105cbd47eaf6f781190fe3eacac607f8affb9b690c00bd70733218d4661a8ed611824dcb3c085537ed6e535a607da83f08ecf153bce375d6 SHA512 e888c3fc0525d406778e51507bffb09f63f8ce553b615bf146a24cf1d91c981e56eee6c4e60ee144d6c30089f58ec1e5559873ae35f9e02dd9bfb23224a09f72
+MISC metadata.xml 384 BLAKE2B 90622968905729ec77151f4afd2ffc7b0561ef1eecc45f1986fccaa0281ae547d3fb88a9d9a63502935070dabd9a0109aa5af76b35132d70b60455d1db8f3864 SHA512 339c2747b1d392528c2b53934ed652574db095407cba130d0c8deac06570dce89e01f5fafb1e9ebe585c88ee3cdcc9f16747c08cdeace6ad47ebdff7f9d5302a
diff --git a/dev-util/buildbot-slave/buildbot-slave-0.8.12.ebuild b/dev-util/buildbot-slave/buildbot-slave-0.8.12.ebuild
new file mode 100644
index 000000000000..bb90f9646953
--- /dev/null
+++ b/dev-util/buildbot-slave/buildbot-slave-0.8.12.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+PYTHON_COMPAT=( python2_7 )
+inherit distutils-r1 readme.gentoo systemd user
+
+DESCRIPTION="BuildBot Slave Daemon"
+HOMEPAGE="http://buildbot.net/ https://github.com/buildbot/buildbot https://pypi.org/project/buildbot-slave/"
+
+MY_PV="${PV/_p/p}"
+MY_P="${PN}-${MY_PV}"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha amd64 arm hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc x86 ~amd64-linux"
+IUSE="test"
+
+RDEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
+ dev-python/twisted-core[${PYTHON_USEDEP}]"
+DEPEND="${RDEPEND}
+ test? ( dev-python/mock[${PYTHON_USEDEP}] )"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ enewuser buildbot
+
+ DOC_CONTENTS="The \"buildbot\" user and the \"buildslave\" init script has been added
+ to support starting buildslave through Gentoo's init system. To use this,
+ set up your build slave following the documentation, make sure the
+ resulting directories are owned by the \"buildbot\" user and point
+ \"${ROOT}etc/conf.d/buildslave\" at the right location. The scripts can
+ run as a different user if desired. If you need to run more than one
+ build slave, just copy the scripts."
+}
+
+src_install() {
+ distutils-r1_src_install
+
+ doman docs/buildslave.1
+
+ newconfd "${FILESDIR}/buildslave.confd" buildslave
+ newinitd "${FILESDIR}/buildslave.initd" buildslave
+ systemd_dounit "${FILESDIR}/buildslave.service"
+
+ readme.gentoo_create_doc
+}
+
+pkg_postinst() {
+ readme.gentoo_print_elog
+}
diff --git a/dev-util/buildbot-slave/files/buildslave.confd b/dev-util/buildbot-slave/files/buildslave.confd
new file mode 100644
index 000000000000..4ef42c4a7333
--- /dev/null
+++ b/dev-util/buildbot-slave/files/buildslave.confd
@@ -0,0 +1,9 @@
+# Path to the build slave's basedir.
+BASEDIR="/var/lib/buildslave"
+
+# User account for the buildslave.
+# The basedir should be owned by this user.
+USERNAME="buildbot"
+
+# Extra options passed to twistd.
+TWISTD_OPTS=""
diff --git a/dev-util/buildbot-slave/files/buildslave.initd b/dev-util/buildbot-slave/files/buildslave.initd
new file mode 100644
index 000000000000..587c7ccb3bb5
--- /dev/null
+++ b/dev-util/buildbot-slave/files/buildslave.initd
@@ -0,0 +1,48 @@
+#!/sbin/openrc-run
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+depend() {
+ need net
+}
+
+checkconfig() {
+ if [ -z "${BASEDIR}" ]; then
+ eerror "BASEDIR not set"
+ return 1
+ fi
+ if [ -z "${USERNAME}" ]; then
+ eerror "USERNAME not set"
+ return 1
+ fi
+ if [ ! -d "${BASEDIR}" ]; then
+ eerror "${BASEDIR} is not a directory"
+ return 1
+ fi
+ if [ ! -e "${BASEDIR}/buildbot.tac" ]; then
+ eerror "${BASEDIR} does not contain buildbot.tac"
+ return 1
+ fi
+}
+
+start() {
+ checkconfig || return 1
+ ebegin "Starting buildslave in ${BASEDIR}"
+ # We set HOME here to make something valid show up in the env of child
+ # processes spawned by the buildslave.
+ start-stop-daemon --start -u "${USERNAME}" \
+ --pidfile "${BASEDIR}/buildslave.pid" \
+ --env HOME="${BASEDIR}" \
+ --exec /usr/bin/python -- /usr/bin/twistd \
+ --no_save \
+ --logfile="${BASEDIR}/twistd.log" \
+ --pidfile="${BASEDIR}/buildslave.pid" \
+ --python="${BASEDIR}/buildbot.tac"
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping buildslave in ${BASEDIR}"
+ start-stop-daemon --stop --pidfile "${BASEDIR}/buildslave.pid"
+ eend $?
+}
diff --git a/dev-util/buildbot-slave/files/buildslave.service b/dev-util/buildbot-slave/files/buildslave.service
new file mode 100644
index 000000000000..5c8e483fe83a
--- /dev/null
+++ b/dev-util/buildbot-slave/files/buildslave.service
@@ -0,0 +1,15 @@
+[Unit]
+Description=buildbot slave instances
+After=local-fs.target network.target
+
+[Service]
+Type=forking
+User=buildbot
+WorkingDirectory=/var/lib/buildslave
+# The following assume there is a 'slave' directory
+# in $WorkingDirectory with the slave configuration files
+ExecStart=/usr/bin/buildslave start slave
+ExecStop=/usr/bin/buildslave stop slave
+
+[Install]
+WantedBy=multi-user.target
diff --git a/dev-util/buildbot-slave/metadata.xml b/dev-util/buildbot-slave/metadata.xml
new file mode 100644
index 000000000000..87ac9774fee6
--- /dev/null
+++ b/dev-util/buildbot-slave/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>hwoarang@gentoo.org</email>
+ <name>Markos Chandras</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="pypi">buildbot-slave</remote-id>
+ <remote-id type="github">buildbot/buildbot</remote-id>
+ </upstream>
+</pkgmetadata>