fix supported drivers list for darwin/arm64

pull/10452/head
Ilya Zuyev 2021-02-10 16:56:35 -08:00
parent 7536f4436c
commit 60bafd00fa
1 changed files with 22 additions and 10 deletions

View File

@ -16,10 +16,21 @@ limitations under the License.
package driver package driver
import "os/exec" import (
"os/exec"
"runtime"
)
// supportedDrivers is a list of supported drivers on Darwin. // supportedDrivers is a list of supported drivers on Darwin.
var supportedDrivers = []string{ var supportedDrivers []string = func() []string {
if runtime.GOARCH == "arm64" {
// on darwin/arm64 only docker and ssh are supported yet
return []string{
Docker,
SSH,
}
}
return []string{
VirtualBox, VirtualBox,
Parallels, Parallels,
VMwareFusion, VMwareFusion,
@ -27,7 +38,8 @@ var supportedDrivers = []string{
VMware, VMware,
Docker, Docker,
SSH, SSH,
} }
}()
func VBoxManagePath() string { func VBoxManagePath() string {
cmd := "VBoxManage" cmd := "VBoxManage"