In 2020 CircleCI introduced the next generation (next-gen) of convenience images. These new images are designed to replace the legacy convenience images that were released during the announcement of CircleCI 2.0. The next-gen CircleCI convenience images are designed from the ground up for a CI/CD environment. They are designed to be faster, more efficient, and most importantly, more reliable. You can learn more about all of the features on our blog post. As we begin to deprecate the legacy images, this document provides information on the migration process.
Moving from a legacy to next-gen image requires a change to the namespace. All legacy images have a Docker namespace of circleci
, while next-gen images have a Docker namespace of cimg
. For example, migrating from the legacy Ruby or Python image to the respective next-gen image can be done as follows:
circleci/ruby:2.3.0 → cimg/ruby:2.3.0
circleci/python:3.8.4 → cimg/python:3.8.4
Table of Contents
Changes
Deprecated images
Several changes are being made to existing images. The following images will be deprecated without next-gen equivalents:
buildpack-deps
JRuby
DynamoDB
MongoDB
circleci/buildpack-deps - If you are using this image, the suggestion is to use the new CircleCI Base image, cimg/base.
circleci/[jruby|dynamo|mongo] - If you are using these images, the suggestion is to use the official Docker Library image instead., jruby, dynamo, mongo. Since these images might miss a few tools, you might want to pre-install a few things before the checkout
step. For example:
jobs:
build:
docker:
- image: jruby:9.3
steps:
- run: sudo apt-get update && sudo apt-get install -y git sudo tar
- checkout
Also, the following image will be renamed:
- The Go image will be changed from
golang
togo
All Legacy to Next-Gen image changes are captured below in this table:
Legacy Image | Next-Gen Image |
---|---|
circleci/buildpack-deps | cimg/base |
circleci/jruby | jruby |
circleci/dynamodb | dynamo |
circleci/golang | cimg/go |
circleci/mongo | mongo |
Browser Testing
With legacy images, there were 4 different variant tags you could use to get browser testing for a particular image. For example, if you were doing browser testing with the Python v3.7.0 image, you might have used Docker image: circleci/python:3.7.0-browsers. These 4 tags have now been consolidated into a single tag designed to be used together with the CircleCI Browser Tools orb.
Legacy Variant Tags | Next-gen Variant Tags |
---|---|
-browsers | -browsers + Browser Tools Orb |
-browsers-legacy | |
-node-browsers | |
-node-browsers-legacy |
The new, single browsers variant tag includes Node.js, common utilities to use in browser testing such as Selenium, but not the actual browsers. Please note the browsers are no longer pre-installed. Instead, browsers such as Google Chrome and Firefox, as well as their drivers Chromedriver and Gecko, are installed via the browsers-tools
orb. This provides the flexibility to mix and match the browser versions you need in a build rather than using strictly what CircleCI provides. You can find examples of how to use this orb here.
Using Ubuntu as the Single Base OS
Legacy images had variant tags for several different base operating systems. Some images were versions of Debian and Ubuntu, while other images provided several different bases. This is no longer the case. All CircleCI next-gen images are based on the latest LTS release of Ubuntu.
With the base image, at least two LTS releases and non-EOL’d standard releases will be supported.
Latest Tag
This tag no longer exists for any image.
Image Specific Changes
Android
The tagging scheme has changed from API level based to date based. This now means that multiple API versions are available at the same time. Any one Android image tag will have at least the 5 most recent API levels.
Go
GOPATH
has been changed from /go
to $HOME/go
. The latter will expand to the full path of /home/circleci/go
. On first run, this change may affect caching and some other commands if you don’t correct the page in your config.
PHP
PHP releases from November 2021 and on no longer use apt-get
to manage PHP and extensions. Instead PHP is compiled from source and extensions should be installed with a tool such a PECL. Please see the cimg/php readme.
Python
Python is installed via pyenv. Everything should work more or less the same, but the location of Python and installed pip modules will be different. Interested in Python site-packages
? You can always know where this directory is located by running: python -m site --user-site
Deprecation Timeline
For all images but Clojure, MariaDB, MySQL, Redis, and MongoDB.
- Jan 1, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt every 24 hours from upstream images.
- Aug 9, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt every 7 days, on a Monday, from upstream images. This means upstream changes, such as new software releases, will take longer, up to 7 days, to be available.
- Sep 20, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt every 14 days, on a Monday, from upstream images. This means upstream changes, such as new software releases, will take longer, up to 14 days, to be available.
- Oct 18, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt once a month, on the 18th, from upstream images. This means upstream changes, such as new software releases, will take longer, up to 30 days, to be available.
- Dec 31, 2021 - Legacy Convenience Images are no longer supported. This will be the last publishing day of these images. Existing tags will still exist on Docker Hub but will remain unchanged. There will be no support for bug or security fixes for existing tags. No new tags will be published after this day.
For only Clojure, MariaDB, MySQL, Redis, and MongoDB.
- Jan 1, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt every 24 hours from upstream images.
- Aug 9, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt every 7 days, on a Monday, from upstream images. This means upstream changes, such as new software releases, will take longer, up to 7 days, to be available.
- Sep 20, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt every 14 days, on a Monday, from upstream images. This means upstream changes, such as new software releases, will take longer, up to 14 days, to be available.
- Dec 13, 2021 - Legacy Convenience Images are in Maintenance Mode only. They are rebuilt once a month, on the 6th, from upstream images. This means upstream changes, such as new software releases, will take longer, up to 30 days, to be available.
- Feb 7, 2022 - Legacy Convenience Images (except Clojure) are no longer supported. This will be the last publishing day of these images. Existing tags will still exist on Docker Hub but will remain unchanged. There will be no support for bug or security fixes for existing tags. No new tags will be published after this day.
- March 7, 2022 - The Clojure Legacy Convenience Image is no longer supported. This will be the last publishing day for this image. Existing tags will still exist on Docker Hub but will remain unchanged. There will be no support for bug or security fixes for existing tags. No new tags will be published after this day.
Troubleshooting
When migrating to a next-gen image, there might be some software issues. Common issues include:
- A library you were using now has a different version.
- An apt package is no longer pre-installed. In this scenario simply install that package using:
sudo apt-get update && sudo apt-get install -y <the-package>
Each image has its own GitHub repository. You can find them here. These repositories are where you can learn more about an image, what makes up the image, open GitHub issues, and contribute PRs. If you are having an issue with an image, especially if it is a migration issue, you can open up a GitHub issue and ask questions. You can also open a support ticket or comment right here in this post.
If this post pertains to you, you may want to bookmark it. We will continually update this post will more information as we go.