Mac at Any Scale namespace.so · 75 points · 18 comments · HN thread TL;DR Namesp...

@best

Mac at Any Scale namespace.so · 75 points · 18 comments · HN thread

TL;DR Namespace, a cloud CI/build provider, explains how it runs fleets of MacBook Pros and Mac minis in its datacenters to offer macOS instances that start in seconds and get new Xcode versions within hours of Apple's release. The post covers why laptops were chosen (Mac mini shortages), the rack design, Apple Virtualization framework limits (two macOS VMs per physical Mac), networking, and a peer-to-peer, sparse-file image distribution system.

  • Customers need Macs for iOS builds and App Store submissions; the iOS Simulator and recent Xcode versions only run on macOS.
  • Mac minis ordered in January were delivered in July, so Namespace used MacBook Pros for its racks; the MacBooks get IP KVMs, external 10G NICs and custom heat holders.
  • Apple's Virtualization framework allows only two macOS VMs per physical Mac, so instances are sized as halves (6 or 12 cores on 14-core minis, 8 or 16 on 18-core MacBooks).
  • Problems were in unexpected places: HDMI cables for KVM, FileVault unlock prompts timing out after 5 minutes after unplanned reboots, and USB NICs losing link until the network service is recreated.
  • VM images reach 500 GB or more; Namespace stores them as sparse, layered images in its OCI-based registry and spreads them across nodes peer-to-peer, using APFS hole and clone features on each node.
  • Current networking reaches about 4 Gbps upstream via a gVisor-based userspace gateway, below line rate because of IPC overhead.

Discussion The thread mixes admiration for the engineering with debate about Apple's licensing and cloud Mac pricing. Several commenters ask whether running Macs in VMs violates Apple's EULA, and the answer given is that Apple permits two virtualized Macs per physical machine, which Namespace stays within. Others discuss whether Apple's two-VM limit makes business sense, and whether non-Apple tooling like xtool can avoid macOS entirely for iOS builds. A large share of comments question cloud Mac prices against buying a Mac mini outright. The mood is mostly appreciative and curious, with a few skeptical notes.

  • Admiration for the engineering and workarounds (many): Commenters praise the creative solutions to Apple hardware and software limitations, especially the registry and peer-to-peer image distribution, and look forward to the promised follow-up post.
  • Cloud Mac pricing is too high versus buying hardware (many): One commenter calculates that a $900 Mac mini pays for itself in about nine months of hourly CI usage at quoted rates, questioning who signs up before running the numbers. Others suggest the premium is for outsourced DC operations.
  • Apple's two-VM limit is questionable (some): Some argue Apple's restriction on virtualized macOS may be commercially shortsighted and that opening it up would let more developers build Apple apps, though others suspect it protects hardware sales and clone farms.
  • Licensing concerns about selling macOS VMs (some): Early comments ask whether reselling macOS VMs breaks the Apple EULA; replies say the two-VM-per-Mac rule is respected and that Hackintosh-style use is a separate question.
  • You can build iOS apps without a Mac (a few): A minority points to xtool and Linux-based environments as alternatives, but another commenter notes it still needs an Xcode bundle taken from a Mac for the iOS headers, so a Mac is still needed in practice.

Links from the comments

#macOS #iOS #datacenter #virtualization #cloudInfrastructure #buildSystems