Skip to content

Commit

Permalink
Bump default CPU cores (#86)
Browse files Browse the repository at this point in the history
To prevent frustrations like #68
  • Loading branch information
fkorotkov authored May 18, 2022
1 parent 7fec41b commit a1bcbdb
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Sources/tart/VM.swift
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ class VM: NSObject, VZVirtualMachineDelegate, ObservableObject {
cpuCountMin: requirements.minimumSupportedCPUCount,
memorySizeMin: requirements.minimumSupportedMemorySize
)
// allocate at least 4 CPUs because otherwise VMs are frequently freezing
try config.setCPU(cpuCount: max(4, requirements.minimumSupportedCPUCount))
try config.save(toURL: vmDir.configURL)

// Initialize the virtual machine and its configuration
Expand Down

0 comments on commit a1bcbdb

Please sign in to comment.