opam 2.5.0 was released on 27th November, and this update needs to be propagated through the CI infrastructure. This post mirrors the steps taken for the release of opam 2.4.1.
Base Images
Linux
The Linux base images are created using the Docker base image builder, which uses ocurrent/ocaml-dockerfile to know which versions of opam are available. Antonin submitted PR#249 with the necessary changes. This was released as v8.3.4.
With v8.3.4 released, PR#336 can be opened to update the pipeline to build images which include opam 2.5. Rebuilding the base images requires a significant amount of time, especially since it’s marked as a low-priority task on the cluster.
macOS
Including opam 2.5 in the macOS required PR#58, which adds 2.5 to the list of opam packages to download. There are Ansible playbooks that build the macOS base images and recursively remove the old images and their (ZFS) clones. They take about half an hour per machine. I run the Intel and Apple Silicon updates in parallel, but process each pool one at a time.
The Ansible command is: ansible-playbook update-ocluster.yml
FreeBSD
The FreeBSD update parallels the macOS update, requiring that 2.5 be added to the loop of available versions. PR#20.
The Ansible command is: ansible-playbook update.yml
Windows (thyme.caelum.ci.dev)
The Windows base images are built using a Makefile which runs unattended builds of Windows using QEMU virtual machines. The Makefile requires PR#202. The build command is make windows.
Once the new images have been built, stop ocluster worker and move the new base images into place. The next is to remove results/* as these layers will link to the old base images, and remove state/* so obuilder will create a new empty database on startup. Avoid removing cache/* as this is the download cache for opam objects.
The unattended installation can be monitored via VNC by connecting to localhost:5900.
OpenBSD (oregano.caelum.ci.dev)
The OpenBSD base images are built using the same Makefile used for Windows. There is a separate commit in PR#202 for the changes needed for OpenBSD, which include moving from OpenBSD 7.6 to 7.7. Run make openbsd.
Once the new images have been built, stop ocluster worker and move the new base images into place. The next is to remove results/* as these layers will link to the old base images, and remove state/* so obuilder will create a new empty database on startup. Avoid removing cache/* as this is the download cache for opam objects.
As with Windows, the unattended installation can be monitored via VNC by connecting to localhost:5900.
OCaml-CI
OCaml-CI uses ocurrent/ocaml-dockerfile as a submodule, so the module needs to be updated to the released version. Edits are needed to lib/opam_version.ml to include V2_5, then the pipeline needs to be updated in service/conf.ml to use version 2.5 rather than 2.4 for all the different operating systems. Linux is rather more automated than the others.
opam-repo-ci
opam-repo-ci tests using the latest tagged version of opam, which is called opam-dev within the base images. It also explicitly tests against the latest release in each of the 2.x series. With 2.5 being tagged, this will automatically become the used dev version once the base images are updated, but over time, 2.5 and the latest tagged version will diverge, so PR#463 is needed to ensure we continue to test with the released version of 2.5.