Bug 1414678 - Pass through MOZ_SCM_LEVEL, so that secret fetching works. r=Callek draft
authorNick Alexander <nalexander@mozilla.com>
Mon, 06 Nov 2017 11:32:40 -0800
changeset 694436 eefc31daa43894a08c9bc9eb1da40faeb466c2a5
parent 693561 2535bad09d720e71a982f3f70dd6925f66ab8ec7
child 739332 aac8c1853490eedcc5e3045e6441646d769029c6
push id88124
push usernalexander@mozilla.com
push dateTue, 07 Nov 2017 19:15:19 +0000
reviewersCallek
bugs1414678
milestone58.0a1
Bug 1414678 - Pass through MOZ_SCM_LEVEL, so that secret fetching works. r=Callek MozReview-Commit-ID: IqtMzMsjxOZ
taskcluster/scripts/builder/build-l10n.sh
testing/mozharness/scripts/desktop_l10n.py
testing/mozharness/scripts/mobile_l10n.py
--- a/taskcluster/scripts/builder/build-l10n.sh
+++ b/taskcluster/scripts/builder/build-l10n.sh
@@ -17,16 +17,18 @@ echo "running as" $(id)
 : MOZHARNESS_CONFIG             ${MOZHARNESS_CONFIG}
 : MOZHARNESS_ACTIONS            ${MOZHARNESS_ACTIONS}
 : MOZHARNESS_OPTIONS            ${MOZHARNESS_OPTIONS}
 
 : TOOLTOOL_CACHE                ${TOOLTOOL_CACHE:=/builds/worker/tooltool-cache}
 
 : NEED_XVFB                     ${NEED_XVFB:=false}
 
+: MOZ_SCM_LEVEL                 ${MOZ_SCM_LEVEL:=1}
+
 : WORKSPACE                     ${WORKSPACE:=/builds/worker/workspace}
 
 set -v
 
 fail() {
     echo # make sure error message is on a new line
     echo "[build-l10n.sh:error]" "${@}"
     exit 1
@@ -90,9 +92,10 @@ cd /builds/worker
 
 python2.7 $WORKSPACE/build/src/testing/${MOZHARNESS_SCRIPT} \
   --disable-mock \
   --revision ${GECKO_HEAD_REV} \
   $actions \
   $options \
   ${config_cmds} \
   --log-level=debug \
+  --scm-level=$MOZ_SCM_LEVEL \
   --work-dir=$WORKSPACE/build \
--- a/testing/mozharness/scripts/desktop_l10n.py
+++ b/testing/mozharness/scripts/desktop_l10n.py
@@ -155,16 +155,25 @@ class DesktopSingleLocale(LocalesMixin, 
          "dest": "en_us_installer_url",
          "type": "string",
          "help": "Specify the url of the en-us binary"}
     ], [
         ["--disable-mock"], {
          "dest": "disable_mock",
          "action": "store_true",
          "help": "do not run under mock despite what gecko-config says"}
+    ], [
+        ['--scm-level'], {  # Ignored on desktop for now: see Bug 1414678.
+         "action": "store",
+         "type": "int",
+         "dest": "scm_level",
+         "default": 1,
+         "help": "This sets the SCM level for the branch being built."
+                 " See https://www.mozilla.org/en-US/about/"
+                 "governance/policies/commit/access-policy/"}
     ]]
 
     def __init__(self, require_config_file=True):
         # fxbuild style:
         buildscript_kwargs = {
             'all_actions': [
                 "clobber",
                 "pull",
--- a/testing/mozharness/scripts/mobile_l10n.py
+++ b/testing/mozharness/scripts/mobile_l10n.py
@@ -115,16 +115,25 @@ class MobileSingleLocale(MockMixin, Loca
          }
     ], [
         ['--revision', ],
         {"action": "store",
          "dest": "revision",
          "type": "string",
          "help": "Override the gecko revision to use (otherwise use buildbot supplied"
                  " value, or en-US revision) "}
+    ], [
+        ['--scm-level'],
+        {"action": "store",
+         "type": "int",
+         "dest": "scm_level",
+         "default": 1,
+         "help": "This sets the SCM level for the branch being built."
+                 " See https://www.mozilla.org/en-US/about/"
+                 "governance/policies/commit/access-policy/"}
     ]]
 
     def __init__(self, require_config_file=True):
         buildscript_kwargs = {
             'all_actions': [
                 "get-secrets",
                 "clobber",
                 "pull",