Bug 1247168 - Configure Mercurial and install global hgrc; r?dustin draft
authorGregory Szorc <gps@mozilla.com>
Wed, 20 Jul 2016 10:22:26 -0700
changeset 390091 24ac382cf613bb4ab5ff011aaae915133c8ac656
parent 390090 57fc6c174fecb51833f06336b7b70458bdc92a1e
child 390092 6ad5071ea519e5cd14243e3bf0bbd66ef919a6af
push id23597
push userbmo:gps@mozilla.com
push dateWed, 20 Jul 2016 17:42:19 +0000
reviewersdustin
bugs1247168
milestone50.0a1
Bug 1247168 - Configure Mercurial and install global hgrc; r?dustin web.cacerts matches what the Ubuntu package does by default. [progress] changes are to make output in TaskCluster logs less spammy (only 1 update per second instead of up to 10). The robustcheckout extension will be used in a subsequent commit to handle repository checkouts.
testing/docker/decision/system-setup.sh
--- a/testing/docker/decision/system-setup.sh
+++ b/testing/docker/decision/system-setup.sh
@@ -34,16 +34,47 @@ tooltool_fetch <<EOF
     "algorithm": "sha512",
     "filename": "mercurial-common_3.8.4_all.deb"
 }
 ]
 EOF
 
 dpkg -i mercurial-common_3.8.4_all.deb mercurial_3.8.4_amd64.deb
 
+mkdir -p /usr/local/mercurial
+cd /usr/local/mercurial
+tooltool_fetch <<'EOF'
+[
+{
+    "size": 11849,
+    "digest": "c88d9b8afd6649bd28bbacfa654ebefec8087a01d1662004aae088d485edeb03a92df1193d1310c0369d7721f475b974fcd4a911428ec65936f7e40cf1609c49",
+    "algorithm": "sha512",
+    "filename": "robustcheckout.py"
+}
+]
+EOF
+
+# Install a global hgrc file with reasonable defaults.
+mkdir -p /etc/mercurial
+cat >/etc/mercurial/hgrc <<EOF
+# By default the progress bar starts after 3s and updates every 0.1s. We
+# change this so it shows and updates every 1.0s.
+[progress]
+delay = 1.0
+refresh = 1.0
+
+[web]
+cacerts = /etc/ssl/certs/ca-certificates.crt
+
+[extensions]
+robustcheckout = /usr/local/mercurial/robustcheckout.py
+EOF
+
+chmod 644 /etc/mercurial/hgrc
+
 # Install node
 tooltool_fetch <<'EOF'
 [
 {
     "size": 5676610,
     "digest": "ce27b788dfd141a5ba7674332825fc136fe2c4f49a319dd19b3a87c8fffa7a97d86cbb8535661c9a68c9122719aa969fc6a8c886458a0df9fc822eec99ed130b",
     "algorithm": "sha512",
     "filename": "node-v0.10.36-linux-x64.tar.gz"