LimaVM Is Probably The Best MacOS Virtual Machine I've Ever Used


LimaVM Is Probably The Best MacOS Virtual Machine I've Ever Used

If you're tired of Docker Desktop bogging down your machine, or simply don't like fuff of mapping ports, mounting volumes when all you need is a small virtual environment, this one's for you.

I recently discovered LimaVM, and it's a game-changer for local development.

It lets you spin up Linux VMs with ease, offering a faster, lighter alternative to Docker and other VM managers for many tasks, but especially for development.

What's the big problem?

Let's face it: containers can be a resource hog, even when they're not, the hypervisor can start eating resources like it's a memory cookie monster.
Remember that feeling when you're trying to quickly test an application, but you mess up the port mapping, then mount the wrong path and env vars, then it takes forever to start, eats up your CPU, and drains your battery?

I've been there, struggling with permissions, and a sluggish shared file system.

It's a frustrating experience that eats into valuable development time, and this builds over over time.

How do most people solve it?

Many developers default to Docker, or even expensive cloud-based VMs, to create the Linux environments they need for building, testing, and running software.

While these solutions work, they often come with significant overhead, not to mention the cost of holding unnecessary resources in the cloud.

Docker Desktop or its alternatives, while convenient, can be too heavy for simple development tasks, especially on older or less powerful machines.

Cloud VMs add complexity and cost, not to mention the risk of not wiring things up correctly, leaving your previous code and secrets exposed (which in turns require another setup of proper tunneling, permissions management, and... you get the point).

Local development can be done right, but it doesn't have to be a pain

Enter LimaVM.

It provides a best-of-all-worlds way to run Linux VMs on MacOS (but not only macs), with minimal overhead.

It handles networking, file sharing, and port mapping automatically, so you can access your web app, and local files to work on without even mentioning it:

Lima assumes you need them by default.

It's fully compatible with container runtimes like containerd (which it was initially built to promote!). It's designed for developers, offering a simple CLI that gets out of your way.

Putting LimaVM into Action

Getting started with LimaVM is straightforward. If you are on MacOS, you can install Lima with brew:

brew install lima

Then, simply run:

lima start

Lima will set up a default Ubuntu VM geared for Docker. You can then access it using:

lima shell

This will drop you into a shell within the VM, with your local file system mounted and ready to go.

From there, you can install dependencies, run your code, and test your applications.

You can even run containers using Nerdctl (if you're crazy enough to do so 😅)

Why This Matters

LimaVM offers a compelling alternative to Docker, or any other form of virtualization for local development. It's faster, lighter, and easier to use.

Whether you're building containerized applications or just need a Linux environment for testing, LimaVM can significantly improve your workflow.

"Lima has a developer first mindset it doesn't force you into guies or complex configs there's a simple CLI that gets out of your way when all you need is work"


Exploring Further

LimaVM is highly customizable.

You can explore different templates for various Linux distributions and container engines.

Check out the official documentation at https://limavm.io for more information.


Thank you for reading.
Feel free to reply directly with any question or feedback.
Have a great weekend!

ESPRESSO FRIDAYS

Every once in a while I send hand picked things I've learned. Kind of like your filter to the tech internet. No spam, I promise!

Read more from ESPRESSO FRIDAYS

He Made $64K Searching GitHub With A GENIUS Trick (using open source only) This issue is brought to you by: TestSprite is the Easiest AI Agent for Software Testing Ensure End-to-End Confidence in Your Software Quality. LEARN MORE This, is the story of how one individual, "Mr. B," leveraged a deep understanding of Git's less-explored features to uncover secrets in public repositories, earning over $64,000 💰. His "genius trick" wasn't about finding new tools, but about using existing Git...

Google's Git Killer Is INSANELY Better (and it's open source) You saw the title. Bold claim, right? "Insanely better"? Than Git? Git is the foundation of modern software development. It started back around 20 years ago, when Linus tried to build his first Linux kernel, and had enough of SVN. So Linus being Linus, he just went ahead and built his own. But what if the way we've always done version control isn't the only way, or even the best way anymore? That's the core idea behind Jujutsu (jj)...

You Need To Learn Docker Swarm! Ever felt like you're overcomplicating your container deployments? You might be. Today, we're diving into a Docker orchestrator that's likely already on your machine (run `docker service` for a second will ya?), but you're probably overlooking: Docker Swarm. The Underdog Orchestrator For years (for me, the past 11 years to be exact), the path has seemed to be either simple Docker Compose or the more, WAY MORE complex, Kubernetes. Compose is great for local...