summaryrefslogtreecommitdiff
path: root/dev-util/buildbot
diff options
context:
space:
mode:
authorMichael Seifert <mseifert@error-reports.org>2016-03-10 19:48:49 +0100
committerPatrice Clement <monsieurp@gentoo.org>2016-03-30 12:03:13 +0000
commit0462b33e75b5061c6671edc5fabf89b53dd1e09f (patch)
tree9dc6c2fa76bdc5d41adb9e7dbd84b8acead6abd8 /dev-util/buildbot
parent0a098cd5685c2a28030738928c689fc6b338cf10 (diff)
downloadgentoo-0462b33e75b5061c6671edc5fabf89b53dd1e09f.tar.gz
gentoo-0462b33e75b5061c6671edc5fabf89b53dd1e09f.tar.xz
dev-util/buildbot: Added support for multiple service instances when using systemd.
This commit adds support for starting multiple buildmaster instances using systemd. A service configuration file allows to specify the filesystem location of the buildmaster instances. A systemd target allows to start up or shut down all buildmaster instances at once. Gentoo-Bug: https://bugs.gentoo.org/570666 Closes: https://github.com/gentoo/gentoo/pull/1027 Signed-off-by: Patrice Clement <monsieurp@gentoo.org>
Diffstat (limited to 'dev-util/buildbot')
-rw-r--r--dev-util/buildbot/buildbot-0.8.12-r2.ebuild4
-rw-r--r--dev-util/buildbot/files/buildmaster.target5
-rw-r--r--dev-util/buildbot/files/buildmaster_at.service16
-rw-r--r--dev-util/buildbot/files/buildmaster_at.service.conf5
4 files changed, 29 insertions, 1 deletions
diff --git a/dev-util/buildbot/buildbot-0.8.12-r2.ebuild b/dev-util/buildbot/buildbot-0.8.12-r2.ebuild
index 99f46ee2bb0..c20323b5509 100644
--- a/dev-util/buildbot/buildbot-0.8.12-r2.ebuild
+++ b/dev-util/buildbot/buildbot-0.8.12-r2.ebuild
@@ -82,7 +82,9 @@ src_install() {
newconfd "${FILESDIR}/buildmaster.confd" buildmaster
newinitd "${FILESDIR}/buildmaster.initd" buildmaster
- systemd_dounit "${FILESDIR}"/${PN}.service
+ systemd_dounit "${FILESDIR}/buildmaster.target"
+ systemd_newunit "${FILESDIR}/buildmaster_at.service" "buildmaster@.service"
+ systemd_install_serviced "${FILESDIR}/buildmaster_at.service.conf" "buildmaster@.service"
readme.gentoo_create_doc
}
diff --git a/dev-util/buildbot/files/buildmaster.target b/dev-util/buildbot/files/buildmaster.target
new file mode 100644
index 00000000000..2bf1a361e6b
--- /dev/null
+++ b/dev-util/buildbot/files/buildmaster.target
@@ -0,0 +1,5 @@
+[Unit]
+Description=Buildbot target that allows to start or stop all buildmaster@*.service instances
+
+[Install]
+WantedBy=multi-user.target
diff --git a/dev-util/buildbot/files/buildmaster_at.service b/dev-util/buildbot/files/buildmaster_at.service
new file mode 100644
index 00000000000..88f9f571200
--- /dev/null
+++ b/dev-util/buildbot/files/buildmaster_at.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=buildbot master daemon
+After=local-fs.target network.target
+PartOf=buildmaster.target
+
+[Service]
+Environment=BASEDIR=/var/lib/buildmaster
+Type=forking
+User=buildbot
+ExecStartPre=/usr/bin/buildbot checkconfig ${BASEDIR}/%i
+ExecStart=/usr/bin/buildbot start ${BASEDIR}/%i
+ExecStop=/usr/bin/buildbot stop ${BASEDIR}/%i
+
+[Install]
+WantedBy=buildmaster.target
+
diff --git a/dev-util/buildbot/files/buildmaster_at.service.conf b/dev-util/buildbot/files/buildmaster_at.service.conf
new file mode 100644
index 00000000000..baf1ae74ec0
--- /dev/null
+++ b/dev-util/buildbot/files/buildmaster_at.service.conf
@@ -0,0 +1,5 @@
+# Uncomment the following lines to configure the base directory for all buildmaster instances.
+
+#[Service]
+#Environment=BASEDIR=/var/lib/buildmaster
+