# Enable SSH (Remote Login) and Screen Sharing (VNC on 5900 inside the guest) { ... }: { name = "remote-access"; script = '' systemsetup -setremotelogin on >/dev/null 2>&1 || launchctl load -w /System/Library/LaunchDaemons/ssh.plist launchctl load -w /System/Library/LaunchDaemons/com.apple.screensharing.plist # allow all local users to screen share defaults write /var/db/launchd.db/com.apple.launchd/overrides.plist com.apple.screensharing -dict Disabled -bool false 2>/dev/null || true ''; }