Orbstack vs Docker Desktop - Running Docker Containers and Linux Machines on MacOS

If you are a developer using a Mac, finding alternatives like OrbStack to optimize Docker performance might be a priority. Docker allows you to create, deploy, and run applications using containers that isolate the software from the environment. Linux is a powerful and versatile operating system that runs most of the servers, cloud platforms, and supercomputers in the world.

But what if you are using a Mac as your primary device?

This is where OrbStack comes in.

It's a fast, light, and simple solution to run Docker containers and Linux machines on macOS. OrbStack lets you run any Docker image or container, any Linux distro or custom image, on your Mac without any hassle. You don’t need to install any additional software or configure any settings. Launch OrbStack from the menu bar and start running your containers and machines.

OrbStack has many features and benefits that make it the best choice for running Docker and Linux on macOS. Here are the top 5:

Features and Benefits of Orbstack

1. Integration with Docker CLI and Docker Compose

OrbStack integrates seamlessly with Docker CLI and Docker Compose, allowing you to use the same commands and files that you are familiar with to run any Docker container on OrbStack.

This means that you don’t need to learn a new set of commands or tools to use OrbStack. You can simply use your existing Docker workflow and enjoy the benefits of OrbStack.

2. Performance and resource efficiency

OrbStack uses native virtualization technologies to run your containers and machines on your Mac.

It starts in just 2 seconds, thanks to its optimized network and file system, and Rosetta emulation. OrbStack has low CPU and disk usage, making it battery-friendly and suitable for Macs with less memory. OrbStack is specially optimized for Macs with Apple Silicon chips, which have a different architecture than Intel-based Macs.

3. Automatic domain names

OrbStack assigns a unique domain name to each container and machine that you create on it. You can use this domain name to access your containers and machines from any browser or app without having to remember their IP addresses or ports.

This makes it easy to share your containers and machines with others or to access them from different devices.

4. VPN and SSH support

OrbStack provides secure connectivity to your containers and machines using VPN or SSH protocols.

You can connect to your containers and machines securely from anywhere in the world using these protocols. This is especially useful if you need to access your containers and machines from public networks or untrusted Wi-Fi hotspots.

5. File system integration

OrbStack allows you to easily share files between your Mac and your containers and machines using drag-and-drop or copy-paste. You can drag files from your Mac and drop them into your containers or machines, or copy files from your containers or machines and paste them into your Mac.

This makes it easy to transfer files between different environments without having to use external tools or services.

Orbstack Promise

OrbStack vs Docker Desktop - how does the Docker Desktop alternative compare?

OrbStack is a Docker Desktop alternative that is designed to offer improved performance for Docker and virtual machines on Linux running on Mac computers. It addresses performance issues that have been experienced in the past, particularly on models with Apple Silicon.

Docker Desktop is a popular tool for running Docker on macOS and Windows. However, it is known to be slower than the core Docker on Linux. The reason for this is that Docker Desktop needs a Linux backend to run Docker containers and images, but macOS and Windows do not have a native Linux kernel.

To solve this problem, the developers of Docker Desktop decided to use a virtual machine (VM) to run the Linux backend. This VM is called MobyLinuxVM and it runs on Hyper-V, which is a native hypervisor for Windows. The VM provides a Linux environment that can run Docker containers and images, but it also adds overhead and complexity to the system. This can result in slower performance, higher resource usage, and more bugs and issues.

Docker Desktop for macOS tends to strain system resources due to several factors. Initially, it employs a lightweight Linux-based virtual machine (VM) to handle containers, creating an additional layer between macOS and applications. This VM consumes substantial memory, CPU, and disk space. Furthermore, it relies on a translation layer, osxfs, to bridge the gap between macOS and Linux file systems, resulting in increased processing and slower file access.

Additionally, the concurrent containers within the VM contend for macOS system resources like CPU, memory, and disk access, potentially causing performance slowdowns.

In contrast, OrbStack is designed to run Docker containers and Linux machines natively on macOS, without the need for a VM or hypervisor. This makes OrbStack faster, lighter, and more reliable than Docker Desktop, especially on Macs with Apple Silicon chips.

OrbStack Benchmark Testing

I ran some of my own tests for OrbStack and here are the results.

Docker image build time

Orbstack vs Docker - build time

As you can see, OrbStack and Docker Desktop have very similar build times, both around 7 minutes. This is not surprising, since they both use the same Docker engine under the hood.

However, OrbStack has a slight edge over Docker Desktop, as it starts faster and has lower CPU and disk usage.

Request handling

Docker vs Orbstack - request handling

For this test, I used two different setups for OrbStack: one with a clean installation running by docker-compose, and another one with Mutagen, a file synchronization tool that I used in my previous posts to speed up Docker for Mac.

I compared them with Docker for Mac with Mutagen, which was the fastest setup in my previous tests.

OrbStack is as fast as Docker for Mac with Mutagen with an average response time of 227ms. This is impressive, considering that OrbStack works that fast out of the box, without any additional configuration.

Adding Mutagen to OrbStack does not make much difference, only slightly improving the performance.

I also tested OrbStack and OrbStack with Mutagen on a newer codebase with Symfony, PHP 8 and other optimizations, and I found that Mutagen made a significant difference there. It doubled the performance of OrbStack. So it seems that Mutagen can still be useful for some projects.

Alternatively, if you want to see our previous benchmarks on MacBook Pro with M1 Pro chip in 2022, you can check it out here.

The test verdict for OrbStack on MacOS

Overall, OrbStack on Mac M1 Pro is solid and highly recommended. It is a great alternative to Docker Desktop for Mac users who want faster performance for Docker and virtual machines on Linux. It is easy to install, lightweight, battery-friendly, and compatible with Docker containers, Kubernetes, and Linux distros.

For ad hoc projects, there is no need to set up Mutagen, as OrbStack is fast enough by itself. But if you work mainly on one project and want to squeeze every bit of performance out of it, you can try adding Mutagen and see if it works better for you.

Docker Deep Dive - free eBook

Docker like a pro!

GET FREE EBOOK

Empowering Mac Users with Docker

In the tech world, running Docker and Linux on Macs has been a challenge. OrbStack changes the game, simplifying the process.

Offering seamless Docker integration, enhanced performance, automatic domain naming, VPN and SSH support, and smooth file sharing, OrbStack outperforms Docker Desktop, especially on Apple Silicon Macs.

OrbStack is equally user-friendly for Linux, providing a range of distros, automatic domain naming, and VPN and SSH capabilities.

Overall, OrbStack is a tool worth exploring, offering accessible and efficient solutions for Docker and Linux users. It's notable that we have incorporated this solution into our own workflows. However, it's important to note that as of late, there is a monthly cost associated with using OrbStack for commercial purposes.

While this change aims to sustain the growth and development of this tool, it's a factor to consider. As we move through 2023 (and possibly 2024), our recommendation leans toward utilizing the MacBook on M1 (or with the silicon chip) in conjunction with OrbStack, keeping in mind the evolving landscape and features offered by both hardware and software.

scale

Ready to make your SaaS Scalable?

Fix most important issues within days from the kick-off

CONTACT USOr contact us directly at: [email protected]

Related posts