0

I found definitions (see below) and how they are usually used (i.e., a Hydra jobset is tracking a git branch) but I still couldn't figure out what they are in the general sense. Maybe if you could explain it laymen's terms with specific examples?

  • Eelco Dolstra, Eelco Visser: "Hydra: A Declarative Approach to Continuous Integration"

    a specification of the location of a Nix expression, along with possible values for the function arguments of the jobs defined by the Nix expression.

  • NixOS Wiki: "Hydra"

    Job Set

    A list of jobs which will be run. Often a Jobset fits to a certain branch (master, staging, stable). A jobset is defined by its inputs and will trigger if these inputs change, e.g. like a new commit onto a branch is added. Job sets may depend on each other

  • Hydra User's Guide

    3.2 Job Sets

    A project can consist of multiple job sets (hereafter jobsets), separate tasks that can be built separately, but may depend on each other (without cyclic dependencies, of course).

My question may seem pointless after listing all these definitions, but here's an examle to demonstrate my confusion: I looked at the project listing at https://hydra.nixos.org/ and I was under the impression that a project is a channel, and jobsets are the branches in a repo. (I know, there is no mention of "channel" in there, and on the channel page it even says that "Nix channels are not supported by this Hydra server." :) I could fool myself with that when looking at the Hydra project but this argument fell apart when I clicked on the flakes one (that is, couldn't find a supporting github repo, but generally the jobset names didn't feel like branch names).

Also, in the Dolstra/Visser paper, Hydra was set up using SVN; I don't know if SVN even uses branches (mostly because the paper didn't mention them) but this does prove that Hydra can be set up with VCS/SCM other than git where the underlying concepts can be fundamentally different. Again, I could easily be wrong.

4

1 回答 1

0

我想我在flox 文档中找到了最好的定义:

在通道内,作业集允许 flox 同时针对多个版本的依赖项构建包

flox 是一个围绕 Nix 生态系统构建的框架,无需安装即可使用 Nix;它无缝地将 Nix 命令传递给远程 Nix 商店和 Hydra 构建农场,就好像它们是在本地机器上发出的一样,因此在安装了 flox 的任何地方都可以始终获得相同的结果。

如果我理解正确的话,

  • 然后,stable作业集将指定通道包的所有依赖项的最新稳定版本作为输入(例如,来自它们的发布分支)

  • staging/unstable将采用依赖项的开发分支(例如master/ main)的最新版本(又名,最前沿)

  • 等等。

自我注意:作业集规范适用于通道中的每个包。


如果以上是正确的,一些挥之不去的问题:

  • 作业集规范是什么样的?例如,stable获取发布分支的最新提交(即HEAD),而staging/unstable会做同样的事情,但对于master/ main(或其他开发)分支?
于 2021-09-18T12:22:25.750 回答