← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] ~cjwatson/lpbuildbot-worker:more-build-variables into lpbuildbot-worker:main

 

Colin Watson has proposed merging ~cjwatson/lpbuildbot-worker:more-build-variables into lpbuildbot-worker:main.

Commit message:
Pass variables to all build steps, not just "build"

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~cjwatson/lpbuildbot-worker/+git/lpbuildbot-worker/+merge/391877

In the PYTHON=python3 case, "make schema" needs it too, and there should be no harm in passing variables to all steps.
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/lpbuildbot-worker:more-build-variables into lpbuildbot-worker:main.
diff --git a/lp-setup-lxd-build b/lp-setup-lxd-build
index 2081944..17dcf03 100755
--- a/lp-setup-lxd-build
+++ b/lp-setup-lxd-build
@@ -115,9 +115,8 @@ def build_launchpad_in_container(container, work_dir, variables):
     for build_step in BUILD_STEPS:
         print("Build step: {}".format(build_step))
         command = ["make", build_step]
-        if build_step == "build":
-            for key, value in variables:
-                command.append("{}={}".format(key, value))
+        for key, value in variables:
+            command.append("{}={}".format(key, value))
         _exec(
             container,
             command,