versioncontrol.rst (2926B)
1 ===================== 2 Version Control in CI 3 ===================== 4 5 Upgrading Mercurial 6 =================== 7 8 Upgrading Mercurial in CI requires touching a handful of different 9 components. 10 11 Vendored robustcheckout 12 ----------------------- 13 14 The ``robustcheckout`` Mercurial extension is used throughout CI to 15 perform clones and working directory updates. The canonical home of 16 the extension is in the 17 https://hg.mozilla.org/hgcustom/version-control-tools repository 18 at the path ``hgext/robustcheckout/__init__.py``. 19 20 21 When upgrading Mercurial, the ``robustcheckout`` extension should also 22 be updated to ensure it is compatible with the version of Mercurial 23 being upgraded to. Typically, one simply copies the latest version 24 from ``version-control-tools`` into the vendored locations. 25 26 The locations are as follows: 27 28 - In-tree: ``testing/mozharness/external_tools/robustcheckout.py`` 29 - Treescript: ``https://github.com/mozilla-releng/scriptworker-scripts/blob/master/treescript/treescript/py2/robustcheckout.py`` 30 - build-puppet: ``https://github.com/mozilla-releng/build-puppet/blob/master/modules/mercurial/files/robustcheckout.py`` 31 - ronin_puppet: ``https://github.com/mozilla-platform-ops/ronin_puppet/blob/master/modules/mercurial/files/robustcheckout.py`` 32 - OpenCloudConfig: ``https://github.com/mozilla-releng/OpenCloudConfig/blob/master/userdata/Configuration/FirefoxBuildResources/robustcheckout.py`` 33 34 35 Debian Packages for Debian and Ubuntu Based Docker Images 36 --------------------------------------------------------- 37 38 ``taskcluster/kinds/packages/debian.yml`` and ``taskcluster/kinds/packages/ubuntu.yml`` 39 define custom Debian packages for Mercurial. These are installed in various 40 Docker images. 41 42 To upgrade Mercurial, typically you just need to update the source URL 43 and its hash in this file. 44 45 46 Windows AMIs 47 ------------ 48 49 https://github.com/mozilla-releng/OpenCloudConfig defines the Windows 50 environment for various Windows AMIs used by Taskcluster. Several of 51 the files reference a ``mercurial-x.y.z-*.msi`` installer. These references 52 will need to be updated to the Mercurial version being upgraded to. 53 54 The ``robustcheckout`` extension is also vendored into this repository 55 at ``userdata/Configuration/FirefoxBuildResources/robustcheckout.py``. It 56 should also be updated if needed. 57 58 Puppet Maintained Hosts 59 ----------------------- 60 61 Some hosts (namely macOS machines) are managed by Puppet and Puppet is used 62 to install Mercurial. 63 64 Puppet code lives in the https://github.com/mozilla-releng/build-puppet repository. 65 Relevant files are in ``modules/mercurial/``, 66 ``modules/packages/manifests/mozilla/mozilla-python27-mercurial-debian/``, 67 and ``modules/packages/manifests/mozilla/py27_mercurial*``. A copy of 68 ``robustcheckout`` is also vendored at 69 ``modules/mercurial/files/robustcheckout.py``. 70 71 .. note:: 72 73 The steps to upgrade Mercurial in Puppet aren't currently captured here. 74 Someone should capture those...