Windows 上的 buildbot 即服务

发布于 2024-10-01 14:15:51 字数 244 浏览 0 评论 0原文

在遵循其网站上列出的关于如何在 Windows 上设置 buildbot 的建议之后,我离开了最后一个问题 - 我在一台计算机上设置了多个从站和一个主站(它们现在都是演示从站,做简单的事情 - 稍后当我们将其中一些分离到他们自己的机器上时,这不会是完全相同的问题),那么我如何将它们全部作为服务运行?我尝试将所有从属/主目录添加到服务中,并尝试再次运行他们的服务设置工具,但无济于事。

我觉得我错过了一些简单的东西,如果有人能指出我正确的方向,我将非常感激。

After following the suggestions outlined on their website on how to set up buildbot on windows, I'm left with one last question - I have multiple slaves and one master all set up on one computer (they're all demo slaves right now, doing simple things - later on when we split some of these off to their own machines this won't be quite the same problem), so how do I run them all as services?? I tried adding all my slave/master directories to the service, and I tried running their service set up tool again, to no avail.

I feel like I'm missing something simple, and would really appreciate it if someone could point me in the right direction.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

若无相欠,怎会相见 2024-10-08 14:15:51

好吧,我链接到的维基百科上给出的建议是错误的。他们建议使用 regedit 添加参数...由于某种原因,无法在那里指定多个构建目录。在 buildbot_service.py 中,概述了实际应该做什么:

#   - Start Control Panel->Administrative Tools->Services
#   - Locate the previously installed buildbot service.
#   - Open the "properties" for the service.
#   - Enter the directory names into the "Start Parameters" textbox.  The
#     directory names must be fully qualified, and surrounded in quotes if
#    they include spaces.
#   - Press the "Start"button.

这里,可以输入多个目录,用空格分隔!

Okay, the advice given on the wiki I linked to was wrong. They suggest using regedit to add parameters... for some reason multiple build directories can't be specified there. In buildbot_service.py, it's outlined what should actually be done:

#   - Start Control Panel->Administrative Tools->Services
#   - Locate the previously installed buildbot service.
#   - Open the "properties" for the service.
#   - Enter the directory names into the "Start Parameters" textbox.  The
#     directory names must be fully qualified, and surrounded in quotes if
#    they include spaces.
#   - Press the "Start"button.

Here, multiple directories can be entered, separated by spaces!

沉默的熊 2024-10-08 14:15:51

首先,我意识到这已经很古老了。
其次,这对我来说可能比什么都重要。

来自有关启动 Windows 服务的 Buildbot 文档: http://docs.buildbot.net/current/manual/installation/misc.html#launching-worker-as-windows-service 有关于创建名为 parameters (HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\BuildBot\Parameters) 并创建一个名为 directories 的字符串条目 (REG_SZ) 和工作程序的基本目录的绝对路径的值。

对于多个工作进程(和/或主进程),将 directories 条目的值设置为分号 ; 分隔的各个基目录的绝对路径列表。

Firstly, I realise this is very old.
Secondly, this is probably more for me than anything.

From the Buildbot documentation on launching a windows service: http://docs.buildbot.net/current/manual/installation/misc.html#launching-worker-as-windows-service there are instructions for making a registry entry called parameters (HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\BuildBot\Parameters) and creating a string entry (REG_SZ) with the name directories and a value of the absolute path of the base directory for the worker.

For multiple workers (and/or masters) set the value of the directories entry to a semi-colon ; separated list of absolute paths to the respective base directories.

花开柳相依 2024-10-08 14:15:51

一个从站可以同时运行多个构建,因此您可能只需要在给定机器上有一个从站。

A slave can run multiple builds at the same time, so you probably only need one slave on a given machine.

云淡风轻 2024-10-08 14:15:51

这是一个古老的问题,但它仍然是 2024 年的热门搜索结果。Hugh 的一个答案解释了如何使用注册表和分号分隔的目录来执行此操作。

根据我的经验,您可能希望系统上的每个工作人员有不同的环境,以便使用不同的工具链。

为此,我根本没有使用 buildbot Windows Worker 的东西。我为设置环境的每个工作人员创建了一个批处理文件,然后使用 Non-Sucking Service Mangaer 为每个工作人员创建一个服务。 NSSM 为您提供了相当程度的控制。

https://nssm.cc/

Ancient question, but it's still the top search result in 2024. There's an answer from Hugh that explains how to do this using the registry and semicolon-separated directories.

In my experience, you probably want a different environment for each worker on the system so as to use different toolchains.

To this end, I didn't use the buildbot windows worker stuff at all. I created a batch file for each worker that set up the environment, and then used the Non-Sucking Service Mangaer to create one service per worker. NSSM gives you a decent amount of control.

https://nssm.cc/

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文