Skip to content

Commit

Permalink
Blog - Show Docker provider performance (#151)
Browse files Browse the repository at this point in the history
  • Loading branch information
rfay authored Nov 29, 2023
1 parent 5595648 commit 01cc674
Show file tree
Hide file tree
Showing 5 changed files with 59 additions and 1 deletion.
1 change: 1 addition & 0 deletions public/img/blog/2023/11/d10_web_install_mutagen.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions public/img/blog/2023/11/d10_web_install_no_mutagen.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/blog/2023/11/whale-race.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ categories:
- Performance
---

I wrote about performance comparisons between [Docker Desktop](https://www.docker.com/products/docker-desktop/) and [Colima](https://github.com/abiosoft/colima) on macOS both with and without [Mutagen](https://ddev.readthedocs.io/en/latest/users/install/performance/#mutagen) in [March, 2022](https://ddev.com/ddev-local/docker-desktop-and-colima-benchmarking-on-macos/), and wanted to update the numbers. Things are looking great everywhere. There are now many more permutations, though. Colima has 9p and VirtioFS file mounting, and Docker Desktop’s VirtioFS implementation now works well (and is fast!).
I wrote about performance comparisons between [Docker Desktop](https://www.docker.com/products/docker-desktop/) and [Colima](https://github.com/abiosoft/colima) on macOS both with and without [Mutagen](https://ddev.readthedocs.io/en/latest/users/install/performance/#mutagen) in March, 2022, and wanted to update the numbers. Things are looking great everywhere. There are now many more permutations, though. Colima has 9p and VirtioFS file mounting, and Docker Desktop’s VirtioFS implementation now works well (and is fast!).

(**Edited 2022-12-28**: Colima version 0.5.2 solved a couple of significant performance problems with VirtioFS mounting, so I updated the fantastic numbers and removed the caveat about `ddev import-db` being slow.)

Expand Down
56 changes: 56 additions & 0 deletions src/content/blog/docker-performance-2023.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
---
title: "macOS Docker Provider Performance, November 2023"
pubDate: 2023-11-30
#modifiedDate: 2023-11-30
summary: "Comparisons of Docker provider performance on macOS using OrbStack, Docker Desktop, and Colima"
author: "Randy Fay"
featureImage:
src: /img/blog/2023/11/whale-race.jpg
alt: Cartoon race with three whales competing in a running race
credit: "Image generated by OpenAI's DALL-E: A whimsical, wide-format scene depicting three whales, each uniquely designed and humorously wearing athletic gear, competing in a running race."
categories:
- DevOps
- Performance
---

## Background

Docker providers for macOS have been getting better and faster (mostly) over time, and [DDEV has recently added OrbStack and Rancher Desktop to its officially supported providers](/blog/docker-providers). It's time to take a look and see what is happening with DDEV and Docker provider performance.

This test used an update of the same technique used in [December 2022](/blog/ddev-docker-desktop-and-colima-benchmarking-updated-dec-2022/).


## Test Methodology

The test does a Drupal 10 web install (details below), because it's a heavy PHP-access process that exercises both the database and filesystem extensively.

## Results: OrbStack Wins!

We'll start with Mutagen enabled (`ddev config --performance-mode=mutagen`), which is the default for macOS. You'll see that OrbStack has the fastest setup, but that all five of the configurations are in a similar range. You would probably be happy with any of them.

![macOS Docker provider performance with Mutagen - OrbStack faster but all configurations probably fine](/img/blog/2023/11/d10_web_install_mutagen.svg)

Now, with Mutagen disabled (`ddev config --performance-mode=none`), OrbStack is by far the fastest, with Docker Desktop coming next and Rancher Desktop and Colima (both configurations) looking pretty sluggish. It's possible that OrbStack could be used without Mutagen, but I don't have any experience with that. Colima with SSHFS definitely cannot be used without Mutagen due to consistency problems with SSHFS.

![macOS Docker provider performance without Mutagen - OrbStack way faster, Colima way too slow](/img/blog/2023/11/d10_web_install_no_mutagen.svg)

**I should note that I'm super happy with DDEV and all of these Docker Providers and the crazy-wonderful [Mutagen](https://mutagen.io) project that have brought such great improvements in performance.** Circa 2018, a Drupal web installation without NFS or Mutagen could take 7 minutes. Now it's 30 seconds or less. That's amazing.

## Details

I used the [ddev-puppeteer](https://github.com/ddev/ddev-puppeteer) project to run the tests. Want to try it against your system or configuration? I'd love to hear your results.

See the [spreadsheet with the raw data](https://docs.google.com/spreadsheets/d/14d79oUItssfB1_spUjjGOPkhumARXyhF0DNBK1kp2KA/edit?usp=sharing)

* DDEV v1.22.5
* Drupal 10.1.6 with Drush (`ddev config --project-type=drupal10 --docroot=web --create-docroot && ddev composer create drupal/recommended-project -y && ddev composer require drush/drush && ddev start`)
* PHP 8.1
* MacBook Air (M1, 2020), 16GB RAM, plugged in
* Docker Desktop 4.25.2
* Colima v0.6.6, Lima v0.18.0, QEMU 8.1.3 (`colima start qemutest --cpu 4 --memory 6 --disk 100 --dns=1.1.1.1 --vm-type=qemu --mount-type=sshfs` and `colima start vztest --cpu=4 --memory=6 --disk=100 --mount-type=virtiofs`)
* Rancher Desktop 1.11.0
* OrbStack 1.1.0

## Summary

You'll probably like any of these Docker providers with DDEV (using Mutagen) based on your choice of performance, maintenance characteristics, and open-source vs. commercial products. My own experience at this point is that OrbStack is providing an outstanding product at a modest price, and is also providing great support and reliable updates. The [DDEV Providers Announcement](/blog/docker-providers) explains how you can test out any of these without breaking anything on your system.

0 comments on commit 01cc674

Please sign in to comment.