This is the multi-page printable view of this section. Click here to print.

Return to the regular view of this page.

Installation

Supported host OS:

  • macOS (the latest version is recommended)
  • Linux
  • NetBSD (untested)
  • DragonFlyBSD (untested)
  • Windows (untested)

Prerequisite:

  • QEMU (Required, only if QEMU driver is used)
brew install lima

Hint: specify --HEAD to install the HEAD (master) version. The HEAD version provides early access to the latest features and improvements before they are officially released.

Homebrew formula is available here. Supports macOS and Linux.

sudo port install lima

Port: https://ports.macports.org/port/lima/

Download the binary archive of Lima from https://github.com/lima-vm/lima/releases, and extract it under /usr/local (or somewhere else).

VERSION=$(curl -fsSL https://api.github.com/repos/lima-vm/lima/releases/latest | jq -r .tag_name)
curl -fsSL "https://github.com/lima-vm/lima/releases/download/${VERSION}/lima-${VERSION:1}-$(uname -s)-$(uname -m).tar.gz" | tar Cxzvm /usr/local

# For Lima v1.1 onward
curl -fsSL "https://github.com/lima-vm/lima/releases/download/${VERSION}/lima-additional-guestagents-${VERSION:1}-$(uname -s)-$(uname -m).tar.gz" | tar Cxzvm /usr/local

1 - Source Installation

Installing from Source

If you prefer to build Lima from source, follow these steps:

Prerequisites

Ensure you have the following dependencies installed:

  • git
  • go
  • make

Build and Install

Run the following commands:

git clone https://github.com/lima-vm/lima
cd lima
make
sudo make install

Note: sudo make install is required unless you have write permissions for /usr/local. Otherwise, installation may fail.

Alternative Installation (Without Sudo)

If you prefer installing Lima in your home directory, configure the PREFIX and PATH as follows:

make PREFIX=$HOME/.local install
export PATH=$HOME/.local/bin:$PATH

Building External Drivers

⚠️ Building drivers as external mode is experimental

Lima supports building drivers as external executables. For detailed information on creating and building external drivers, see the Virtual Machine Drivers guide.

Packaging Lima for Distribution

After building Lima from source, you may want to package it for installation on other machines:

  1. The package for the core component and the native guest agent:
make clean native
cd _output
tar czf lima-package.tar.gz *
  1. The package for the additional guest agents:
make clean additional-guestagents
cd _output
tar czf lima-additional-guestagents-package.tar.gz *

These packages can then be transferred and installed on the target system.