dockur/macos: Run macOS in a Docker Container with KVM Acceleration

This repository profile is provided by osrepos.com, an open source repository discovery platform.

dockur/macos: Run macOS in a Docker Container with KVM Acceleration

Summary

dockur/macos is an innovative GitHub project that enables users to run macOS within a Docker container, leveraging KVM acceleration for optimal performance. This solution simplifies the process of setting up a macOS virtual machine, offering a web-based viewer and automatic download of macOS images. It provides a highly convenient and flexible way to access a macOS environment for various purposes, including development and testing.

Repository Information

Analyzed by OSRepos on October 12, 2025

Topics

Click on any tag to explore related repositories

Use at your own risk

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.

Introduction

The dockur/macos project offers a unique solution for running macOS directly inside a Docker container. This innovative approach combines the power of containerization with the functionality of a full macOS environment, enhanced by KVM acceleration for near-native performance. It's an ideal tool for developers, testers, or anyone who needs a flexible and isolated macOS instance without dedicated Apple hardware (though the EULA requires running on Apple hardware).

Key features include:

  • KVM acceleration for high performance.
  • A convenient web-based viewer for easy interaction.
  • Automatic download of macOS images, simplifying setup.
  • Support for various macOS versions, including Sonoma, Ventura, and Monterey.

Installation

Getting dockur/macos up and running is straightforward, primarily using Docker Compose or the Docker CLI.

Via Docker Compose

For a persistent and easily configurable setup, Docker Compose is recommended. Create a docker-compose.yaml file with the following content:

services:
  macos:
    image: dockurr/macos
    container_name: macos
    environment:
      VERSION: "14" # Specify macOS version (e.g., "14" for Sonoma)
    devices:
      - /dev/kvm
      - /dev/net/tun
    cap_add:
      - NET_ADMIN
    ports:
      - 8006:8006 # Web-based viewer
      - 5900:5900/tcp # VNC access
      - 5900:5900/udp # VNC access
    volumes:
      - ./macos:/storage # Persistent storage for macOS
    restart: always
    stop_grace_period: 2m

Then, simply run:

docker compose up -d

Via Docker CLI

For a quick test or single-run instance, you can use the Docker CLI:

docker run -it --rm --name macos -e "VERSION=14" -p 8006:8006 --device=/dev/kvm --device=/dev/net/tun --cap-add NET_ADMIN -v "${PWD:-.}/macos:/storage" --stop-timeout 120 dockurr/macos

After starting the container, access your macOS instance by navigating to http://127.0.0.1:8006/ in your web browser. Follow the on-screen instructions to install macOS, similar to a physical machine.

Examples

dockur/macos offers extensive customization through environment variables. Here are a few common examples:

Changing macOS Version

You can specify which macOS version to install by setting the VERSION environment variable. For example, to install macOS 13 (Ventura):

environment:
  VERSION: "13" # "15" for Sequoia, "14" for Sonoma, "13" for Ventura, etc.

Adjusting Disk Size

Expand the default 64 GB disk size by adding DISK_SIZE:

environment:
  DISK_SIZE: "256G" # Set to your preferred capacity, e.g., "128G", "512G"

Customizing CPU and RAM

Control the resources allocated to your macOS container:

environment:
  RAM_SIZE: "8G" # Allocate 8 GB of RAM
  CPU_CORES: "4" # Assign 4 CPU cores

For more advanced configurations, such as network setup, USB passthrough, or file sharing, refer to the comprehensive FAQ section in the project's GitHub README.

Why Use dockur/macos?

This project stands out for several reasons:

  • Ease of Use: Simplifies the complex process of virtualizing macOS into a few Docker commands.
  • Performance: KVM acceleration ensures that your macOS instance runs efficiently, providing a smooth user experience.
  • Flexibility: Easily spin up different macOS versions, adjust resources, and manage multiple instances.
  • Isolation: Provides a clean, isolated macOS environment, perfect for development, testing, or running specific macOS-only applications without affecting your host system.
  • Accessibility: Access your macOS VM from any web browser, making it highly convenient.

It's important to note the project's disclaimer: "Only run this container on Apple hardware, any other use is not permitted by their EULA. The product names, logos, brands, and other trademarks referred to within this project are the property of their respective trademark holders. This project is not affiliated, sponsored, or endorsed by Apple Inc."

Links

Related repositories

Similar repositories that may be relevant next.

HomeHub: Your Private, Self-Hosted Family Utility Dashboard

HomeHub: Your Private, Self-Hosted Family Utility Dashboard

May 8, 2026

HomeHub is a private, lightweight, and self-hosted web application designed to be your family's all-in-one dashboard. It transforms any computer, even a Raspberry Pi, into a central hub for managing daily household activities, offering features like shared notes, shopping lists, and expense tracking. With no login required and a focus on privacy, all your data remains on your local network, ensuring no cloud dependency or tracking.

HTMLself-hostedfamily-utility
Airo: Effortless Project Deployment from Local to Production VPS

Airo: Effortless Project Deployment from Local to Production VPS

May 3, 2026

Airo is a Go-based tool designed for simple and efficient deployment of projects from a local machine to a production VPS. It automates the process of building Docker images and deploying them via SSH or a registry, making it ideal for self-hosted side projects. This solution offers a straightforward alternative to complex CI/CD pipelines, focusing on speed and control.

devopsself-hostedGo
nebula-sync: Effortlessly Synchronize Your Pi-hole Configurations

nebula-sync: Effortlessly Synchronize Your Pi-hole Configurations

May 2, 2026

nebula-sync is a powerful tool designed to synchronize configurations across multiple Pi-hole v6.x instances. Developed in Go, it offers both full and selective synchronization options, ensuring your ad-blocking setup remains consistent and up-to-date across your network. This project simplifies the management of distributed Pi-hole deployments.

dnsdockergolang
docker-volume-backup: Robust Docker Volume Backups to Multiple Storages

docker-volume-backup: Robust Docker Volume Backups to Multiple Storages

April 23, 2026

docker-volume-backup is a lightweight companion container designed for robust Docker volume backups. It handles recurring or one-off backups to various destinations like S3, WebDAV, Azure Blob Storage, Dropbox, Google Drive, or SSH, and includes features like encryption and old backup rotation. This tool ensures your Docker data is safely stored and easily recoverable.

backupdockerdocker-volume

Source repository

Open the original repository on GitHub.

View on GitHub
OS
OSRepos

Analysis and discovery of open source repositories. Find interesting projects and follow their updates.

Monitor your website with YourWebsiteScore

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of third-party repository code is at your own risk. Always review source code, dependencies, licenses, and security implications before running anything.

© 2025 OSRepos. Built with Nuxt 3 and lots of ❤️