Bug 1269731 - partner-repacks push to mirrors should work on reruns r=nthomas a=release DONTBUILD CLOSED TREE
authorRail Aliiev <rail@mozilla.com>
Tue, 17 May 2016 08:26:37 -0400
changeset 332897 73cd8f727097aa78f01cc0697a55aeae0f1337b8
parent 332896 0b344441f45b2e88ee05787ff5e8f2a4b987b802
child 332898 fc67e4930cc65c77003e4b40aedb6095e9fc5d32
push id6048
push userkmoir@mozilla.com
push dateMon, 06 Jun 2016 19:02:08 +0000
treeherdermozilla-beta@46d72a56c57d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnthomas, release
bugs1269731
milestone48.0a2
Bug 1269731 - partner-repacks push to mirrors should work on reruns r=nthomas a=release DONTBUILD CLOSED TREE MozReview-Commit-ID: 8zc1ppQGxWp
testing/mozharness/scripts/release/push-candidate-to-releases.py
--- a/testing/mozharness/scripts/release/push-candidate-to-releases.py
+++ b/testing/mozharness/scripts/release/push-candidate-to-releases.py
@@ -30,19 +30,36 @@ class ReleasePusher(BaseScript, Virtuale
             "help": "Bucket to copy files from candidates/ to releases/",
         }],
         [["--credentials"], {
             "dest": "credentials",
             "help": "File containing access key and secret access key",
         }],
         [["--exclude"], {
             "dest": "excludes",
-            "default": [],
+            "default": [
+                r"^.*tests.*$",
+                r"^.*crashreporter.*$",
+                r"^.*[^k]\.zip(\.asc)?$",
+                r"^.*\.log$",
+                r"^.*\.txt$",
+                r"^.*/partner-repacks.*$",
+                r"^.*.checksums(\.asc)?$",
+                r"^.*/logs/.*$",
+                r"^.*/jsshell.*$",
+                r"^.*json$",
+                r"^.*/host.*$",
+                r"^.*/mar-tools/.*$",
+                r"^.*robocop.apk$",
+                r"^.*contrib.*",
+                r"^.*/beetmover-checksums/.*$",
+            ],
             "action": "append",
-            "help": "List of patterns to exclude from copy. See script source for default.",
+            "help": "List of patterns to exclude from copy. The list can be "
+                    "extended by passing multiple --exclude arguments.",
         }],
         [["-j", "--parallelization"], {
             "dest": "parallelization",
             "default": 20,
             "type": "int",
             "help": "Number of copy requests to run concurrently",
         }],
     ] + virtualenv_config_options
@@ -80,40 +97,16 @@ class ReleasePusher(BaseScript, Virtuale
         if all(aws_creds):
             self.aws_key_id, self.aws_secret_key = aws_creds
         else:  # use
             self.aws_key_id, self.aws_secret_key = None, None
             # set the env var for boto to read our special config file
             # rather than anything else we have at ~/.boto
             os.environ["BOTO_CONFIG"] = os.path.abspath(self.config["credentials"])
 
-    def _pre_config_lock(self, rw_config):
-        super(ReleasePusher, self)._pre_config_lock(rw_config)
-
-        # This default is set here rather in the config because default
-        # lists cannot be completely overidden, only appended to.
-        if not self.config.get("excludes"):
-            self.config["excludes"] = [
-                r"^.*tests.*$",
-                r"^.*crashreporter.*$",
-                r"^.*[^k]\.zip(\.asc)?$",
-                r"^.*\.log$",
-                r"^.*\.txt$",
-                r"^.*/partner-repacks.*$",
-                r"^.*.checksums(\.asc)?$",
-                r"^.*/logs/.*$",
-                r"^.*/jsshell.*$",
-                r"^.*json$",
-                r"^.*/host.*$",
-                r"^.*/mar-tools/.*$",
-                r"^.*robocop.apk$",
-                r"^.*contrib.*",
-                r"^.*/beetmover-checksums/.*$",
-            ]
-
     def _get_candidates_prefix(self):
         return "pub/{}/candidates/{}-candidates/build{}/".format(
             self.config['product'],
             self.config["version"],
             self.config["build_number"]
         )
 
     def _get_releases_prefix(self):