diff mbox series

[v2,4/5] utils/genrandconfig: do not use BR2_BACKUP_SITE for some builds

Message ID 20240818090346.947914-5-thomas.petazzoni@bootlin.com
State Accepted
Headers show
Series Misc utils/genrandconfig improvements | expand

Commit Message

Thomas Petazzoni Aug. 18, 2024, 9:03 a.m. UTC
In order to test that upstream sites are still working, we need to NOT
fallback to sources.buildroot.net for some builds.

As there is anyway a local cache in the autobuilder instances, we need
to do quite a lot of builds without any BR2_BACKUP_SITE configured to
have a chance to catch issues, which is why a 50% chance is used to
unset BR2_BACKUP_SITE.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
 utils/genrandconfig | 5 +++++
 1 file changed, 5 insertions(+)
diff mbox series

Patch

diff --git a/utils/genrandconfig b/utils/genrandconfig
index 0ccb6d83a6..66296e1954 100755
--- a/utils/genrandconfig
+++ b/utils/genrandconfig
@@ -562,6 +562,11 @@  async def gen_config(args):
         configlines.append("BR2_REPRODUCIBLE=y\n")
         configlines.append("BR2_TARGET_ROOTFS_TAR=y\n")
 
+    # From time to time, ignore sources.buildroot.net to really fetch
+    # from upstream
+    if randint(0, 1) == 0:
+        configlines.append("""BR2_BACKUP_SITE=""\n""")
+
     with open(configfile, "a") as configf:
         configf.writelines(configlines)