A few days ago, I tried manually upgrading Docker Desktop on my personal 2015 MacBook Pro (running macOS Mojave 10.14.6). I went to Docker’s website and downloaded the newest image for my Intel-based Mac, only to find an unhelpful and misleading message from macOS:
Warning: Docker DMG file is corrupt.
Of course I went back to make sure I didn’t click on the ARM version and downloaded a brand new copy, but again, the “corrupt image” warning. A few panicked minutes of thinking I got MITM’d later, I realized it wasn’t a corrupt image at all: my macOS was too old to install the latest and greatest version of Docker.
According to Docker’s macOS System Requirements:
Docker supports Docker Desktop on the most recent versions of macOS.
That is, the current release of macOS and the previous two releases.
As new major versions of macOS are made generally available,
Docker stops supporting the oldest version and supports the newest
version of macOS (in addition to the previous two releases).
The current version of Docker (4.26.0 as of January 2024) supports macOS Sonoma, Ventura, and Monterey. Mac users on Big Sur or an earlier OS will need to find an alternate solution.
I did some digging and found a few different approaches to getting Docker working on my Mac.
Option 1 (Obvious and scary): upgrade macOS
It’s important to consider whether your Docker use case warrants an entire OS upgrade. You might already be avoiding an upgrade for a myriad of reasons. For a few key reasons to think twice before upgrading, check out this article from How-To Geek. Remember, you have other software that might break because of the upgrade, and OS upgrades have been known to slow down older hardware.
These upgrades can take a good chunk of time and are a pretty big commitment if you are just trying to test out a new feature in Compose…
Before upgrading, you might also want to check that your Mac hardware can run Docker’s required macOS version. This article from Macworld lists the Macs supported by each macOS release since OS X Mountain Lion.
Option 2 (Quick and easy): find an old supported version of Docker
Many users, myself included, choose to stay on an older version of macOS on older hardware for performance and/or compatibility reasons. Users with machines that are over four or five years old have no option to upgrade to the latest macOS version (by legitimate means, at least).
If you’d prefer to keep your current OS, you can simply install an older version of Docker. These aren’t listed alongside current downloads on the Docker website, but the links are still live.
This (unofficial) Gist includes the download links to previous Docker versions, expanded by this recent comment. For versions 4.18.0 and up, you can grab a download link directly from the release notes page.
When choosing a previous Docker version, cross reference with the release notes. This way, you can find a version that works with your current OS and includes the features and bug fixes that you need for your use case.
Option 3 (Fun and complex): Running a Linux VM
If you’re unable to upgrade macOS and need the latest version of Docker, there’s a last resort: you can run a Linux distro in a VM (via VirtualBox or QEMB) and install Docker there. This will allow you to use the same version of Docker on your Mac (Docker on macOS runs in a LinuxKit VM), however it’ll be much less optimized and will require more config since you won’t be running it natively.
More Docker for Your Mac
The swap from Intel to Apple Silicon added complexity to third-party software releases, and three years in, we’re seeing shorter support lifespans for Intel Macs. If an OS upgrade isn’t in the cards for you, it’s nice to know that Docker still hosts its older DMGs and that there’s support for mainstream Linux distros.
Want to automate your Docker builds in your CI? Check out this post I did a few months back on using GitHub Actions to build and push Docker images to a container registry.