Skip to content

Commit 7244df6

Browse files
committed
buildbot: 3.11.3 -> 4.0.0
sometimes takes a while for upstream to publish on pypi so switch to using github source for master, pkg, worker and github releases for the plugins which require built assets
1 parent a58313d commit 7244df6

File tree

7 files changed

+50
-64
lines changed

7 files changed

+50
-64
lines changed

nixos/doc/manual/release-notes/rl-2411.section.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@
4747
- For convenience, the top-level `clang-tools` attribute remains and is now bound to `llvmPackages.clang-tools`.
4848
- Top-level `clang_tools_<version>` attributes are now aliases; these will be removed in a future release.
4949

50+
- `buildbot` was updated to 4.0, the AngularJS frontend has been replaced by a React frontend, see the [upstream release notes](https://docs.buildbot.net/current/manual/upgrading/4.0-upgrade.html).
51+
5052
- `nginx` package no longer includes `gd` and `geoip` dependencies. For enabling it, override `nginx` package with the optionals `withImageFilter` and `withGeoIP`.
5153

5254
- `openssh` and `openssh_hpn` are now compiled without Kerberos 5 / GSSAPI support in an effort to reduce the attack surface of the components for the majority of users. Users needing this support can

nixos/tests/buildbot.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import ./make-test-python.nix ({ pkgs, ... }: {
1414
"steps.ShellCommand(command=['bash', 'fakerepo.sh'])"
1515
];
1616
changeSource = [
17-
"changes.GitPoller('git://gitrepo/fakerepo.git', workdir='gitpoller-workdir', branch='master', pollinterval=300)"
17+
"changes.GitPoller('git://gitrepo/fakerepo.git', workdir='gitpoller-workdir', branch='master', pollInterval=300)"
1818
];
1919
};
2020
networking.firewall.allowedTCPPorts = [ 8010 8011 9989 ];

pkgs/development/tools/continuous-integration/buildbot/master.nix

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
, stdenv
33
, buildPythonApplication
44
, fetchFromGitHub
5-
, fetchpatch
65
, makeWrapper
76
# Tie withPlugins through the fixed point here, so it will receive an
87
# overridden version properly
@@ -73,7 +72,7 @@ let
7372
in
7473
buildPythonApplication rec {
7574
pname = "buildbot";
76-
version = "3.11.3";
75+
version = "4.0.0";
7776
format = "pyproject";
7877

7978
disabled = pythonOlder "3.8";
@@ -82,7 +81,7 @@ buildPythonApplication rec {
8281
owner = "buildbot";
8382
repo = "buildbot";
8483
rev = "v${version}";
85-
hash = "sha256-rDbAWLoEEjygW72YDBsVwiaHdRTVYA9IFxY3XMDleho=";
84+
hash = "sha256-uJj7bSRGdYkA7Jl0qe/DncexWXNfQEEPcqGI7AbwX1w=";
8685
};
8786

8887
build-system = [
@@ -137,13 +136,6 @@ buildPythonApplication rec {
137136
# This patch disables the test that tries to read /etc/os-release which
138137
# is not accessible in sandboxed builds.
139138
./skip_test_linux_distro.patch
140-
# Fix gitpoller, source: https://github.com/buildbot/buildbot/pull/7664
141-
# Included in next release.
142-
(fetchpatch {
143-
url = "https://github.com/buildbot/buildbot/commit/dd5d61e63e3b0740cc538a225ccf104ccecfc734.patch";
144-
sha256 = "sha256-CL6uRaKxh8uCBfWQ0tNiLh2Ym0HVatWni8hcuTyAAw0=";
145-
excludes = ["master/buildbot/test/unit/changes/test_gitpoller.py"];
146-
})
147139
];
148140

149141
postPatch = ''
@@ -171,8 +163,11 @@ buildPythonApplication rec {
171163

172164
passthru = {
173165
inherit withPlugins;
174-
tests.buildbot = nixosTests.buildbot;
175166
updateScript = ./update.sh;
167+
} // lib.optionalAttrs stdenv.isLinux {
168+
tests = {
169+
inherit (nixosTests) buildbot;
170+
};
176171
};
177172

178173
meta = with lib; {

pkgs/development/tools/continuous-integration/buildbot/pkg.nix

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
1-
{ lib, buildPythonPackage, fetchPypi, isPy3k, buildbot }:
1+
{ lib, buildPythonPackage, isPy3k, buildbot }:
22

3-
buildPythonPackage rec {
3+
buildPythonPackage {
44
pname = "buildbot_pkg";
5-
inherit (buildbot) version;
6-
7-
src = fetchPypi {
8-
inherit pname version;
9-
hash = "sha256-pO2TmTwbY0cnR+882pl7wDiR6JEK+sHHpAltKmTxiIM=";
10-
};
5+
inherit (buildbot) src version;
116

127
postPatch = ''
8+
cd pkg
139
# Their listdir function filters out `node_modules` folders.
1410
# Do we have to care about that with Nix...?
1511
substituteInPlace buildbot_pkg.py --replace "os.listdir = listdir" ""

pkgs/development/tools/continuous-integration/buildbot/plugins.nix

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
{ lib, buildPythonPackage, fetchPypi, callPackage, mock, cairosvg, klein, jinja2, buildbot-pkg }:
1+
{ lib, buildPythonPackage, fetchurl, callPackage, mock, cairosvg, klein, jinja2, buildbot-pkg }:
22
{
33
# this is exposed for potential plugins to use and for nix-update
44
inherit buildbot-pkg;
55
www = buildPythonPackage rec {
66
pname = "buildbot_www";
77
inherit (buildbot-pkg) version;
88

9-
src = fetchPypi {
10-
inherit pname version;
11-
hash = "sha256-EL5iZ257VXnL+29Jr6r3PVeURX1AcugfZ4RLTjClsXo=";
9+
src = fetchurl {
10+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
11+
hash = "sha256-OzH7ckNL09s4r3f6PIc3q9lLT3NgCdIf0IMwJtwlKiY=";
1212
};
1313

1414
# Remove unnecessary circular dependency on buildbot
@@ -33,9 +33,9 @@
3333
pname = "buildbot_www_react";
3434
inherit (buildbot-pkg) version;
3535

36-
src = fetchPypi {
37-
inherit pname version;
38-
hash = "sha256-5QLw5nXnU+z11E5Tgvu9bbbpCTRpV2zXndukcZPRjtE=";
36+
src = fetchurl {
37+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
38+
hash = "sha256-lfurzhNJ5DvuPCD/WJ3k+ajuZzhNF6zGOgSuuD0/+Ys=";
3939
};
4040

4141
# Remove unnecessary circular dependency on buildbot
@@ -60,9 +60,9 @@
6060
pname = "buildbot_console_view";
6161
inherit (buildbot-pkg) version;
6262

63-
src = fetchPypi {
64-
inherit pname version;
65-
hash = "sha256-tzqifo9A/KJF9dLpO7jblVaDjx7++v0wLz1Olc79JxI=";
63+
src = fetchurl {
64+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
65+
hash = "sha256-uKNqnqUkNkd14/6QcquyWp1v59bNWcTB4s8lRO9hkUc=";
6666
};
6767

6868
buildInputs = [ buildbot-pkg ];
@@ -82,9 +82,9 @@
8282
pname = "buildbot_react_console_view";
8383
inherit (buildbot-pkg) version;
8484

85-
src = fetchPypi {
86-
inherit pname version;
87-
hash = "sha256-fzaqYmaO+vWnQpUvOsPCny3W27atcIHsgeGV6dKEJeg=";
85+
src = fetchurl {
86+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
87+
hash = "sha256-wUrhPbd71F3OfXI5Re1xPnc1/vZxYXxdxX58fnWKjYE=";
8888
};
8989

9090
buildInputs = [ buildbot-pkg ];
@@ -104,9 +104,9 @@
104104
pname = "buildbot_waterfall_view";
105105
inherit (buildbot-pkg) version;
106106

107-
src = fetchPypi {
108-
inherit pname version;
109-
hash = "sha256-BLIs91k8/A4LYMTDgct7TOWFoLU4qK47Javr8qRzkZQ=";
107+
src = fetchurl {
108+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
109+
hash = "sha256-qc5mP7V2cOR3SOt224i8HVoAyWHvVYbsqfIQvPjesmE=";
110110
};
111111

112112
buildInputs = [ buildbot-pkg ];
@@ -126,9 +126,9 @@
126126
pname = "buildbot_react_waterfall_view";
127127
inherit (buildbot-pkg) version;
128128

129-
src = fetchPypi {
130-
inherit pname version;
131-
hash = "sha256-dX+tp+WidfLy612+41jz+do/iXQTaIQPcetG8td3jp4=";
129+
src = fetchurl {
130+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
131+
hash = "sha256-s6L4oF/wTOfM9uKFEJ/mjnQWE6oPRcd32lM1p2ox9+I=";
132132
};
133133

134134
buildInputs = [ buildbot-pkg ];
@@ -148,9 +148,9 @@
148148
pname = "buildbot_grid_view";
149149
inherit (buildbot-pkg) version;
150150

151-
src = fetchPypi {
152-
inherit pname version;
153-
hash = "sha256-2kLGdvmf2mnF21gkDCf6h+bhnsxveaNNh95qczRY824=";
151+
src = fetchurl {
152+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
153+
hash = "sha256-tZRwDqWYjBwguqA6T3ZoY38+QFogXKiTzbg1qjs/spE=";
154154
};
155155

156156
buildInputs = [ buildbot-pkg ];
@@ -170,9 +170,9 @@
170170
pname = "buildbot_react_grid_view";
171171
inherit (buildbot-pkg) version;
172172

173-
src = fetchPypi {
174-
inherit pname version;
175-
hash = "sha256-rIAbk9+6Wi1PCjizHp9p6jpCwaBgBT5Ch1Sa4VKDoww=";
173+
src = fetchurl {
174+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
175+
hash = "sha256-t++yXEgM4l40grSVccjx399TM/vUTmQOSInfH+Wqi50=";
176176
};
177177

178178
buildInputs = [ buildbot-pkg ];
@@ -192,9 +192,9 @@
192192
pname = "buildbot_wsgi_dashboards";
193193
inherit (buildbot-pkg) version;
194194

195-
src = fetchPypi {
196-
inherit pname version;
197-
hash = "sha256-D9mjEKFrh+ytNbpuN/06XbiBnKjFLopXfjDg28j7niw=";
195+
src = fetchurl {
196+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
197+
hash = "sha256-MkrMcaf2UeUYjkwcdhj4rhBwEtVESJEMtGa7RArNLz0=";
198198
};
199199

200200
buildInputs = [ buildbot-pkg ];
@@ -214,9 +214,9 @@
214214
pname = "buildbot_react_wsgi_dashboards";
215215
inherit (buildbot-pkg) version;
216216

217-
src = fetchPypi {
218-
inherit pname version;
219-
hash = "sha256-q3In0IMAIBUjxSzv4LlH9EJukLYJ3WzoEYkFBZB96W8=";
217+
src = fetchurl {
218+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
219+
hash = "sha256-iCAtKOl/8sfCwa3tsK2oQ+ybs0TVF5uWg4Jv/r7oPWg=";
220220
};
221221

222222
buildInputs = [ buildbot-pkg ];
@@ -236,9 +236,9 @@
236236
pname = "buildbot_badges";
237237
inherit (buildbot-pkg) version;
238238

239-
src = fetchPypi {
240-
inherit pname version;
241-
hash = "sha256-TK4KYn3CWxymTsKWeqHr2i5rdO9ZDHvJrb9RqfKNJV4=";
239+
src = fetchurl {
240+
url = "https://github.com/buildbot/buildbot/releases/download/v${version}/${pname}-${version}.tar.gz";
241+
hash = "sha256-28vj6wUZEnVUSUWrveJ5tdIjN+l4RDewPnm3IVQPXn4=";
242242
};
243243

244244
buildInputs = [ buildbot-pkg ];

pkgs/development/tools/continuous-integration/buildbot/update.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
set -eu -o pipefail
44

55
nix-update buildbot
6-
nix-update --version=skip buildbot-worker
7-
nix-update --version=skip buildbot-plugins.buildbot-pkg
86
nix-update --version=skip buildbot-plugins.www
97
nix-update --version=skip buildbot-plugins.www-react
108
nix-update --version=skip buildbot-plugins.console-view

pkgs/development/tools/continuous-integration/buildbot/worker.nix

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
{ lib
22
, buildPythonPackage
3-
, fetchPypi
43
, buildbot
54
, stdenv
65

@@ -22,16 +21,12 @@
2221
, nixosTests
2322
}:
2423

25-
buildPythonPackage (rec {
24+
buildPythonPackage ({
2625
pname = "buildbot_worker";
27-
inherit (buildbot) version;
28-
29-
src = fetchPypi {
30-
inherit pname version;
31-
hash = "sha256-TFymBnUufOEWZ/IUKd7nebZ+yl58ZChFkGrUxOXn28g=";
32-
};
26+
inherit (buildbot) src version;
3327

3428
postPatch = ''
29+
cd worker
3530
substituteInPlace buildbot_worker/scripts/logwatcher.py \
3631
--replace /usr/bin/tail "${coreutils}/bin/tail"
3732
'';

0 commit comments

Comments
 (0)