Skip to content

Commit

Permalink
Merge pull request #3734 from afbjorklund/amd
Browse files Browse the repository at this point in the history
Add flag for disabling the VirtualBox VTX check
  • Loading branch information
afbjorklund committed Feb 27, 2019
2 parents 6af8086 + 167d158 commit 185570b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cmd/minikube/cmd/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ const (
vsockPorts = "hyperkit-vsock-ports"
gpu = "gpu"
embedCerts = "embed-certs"
noVTXCheck = "no-vtx-check"
)

var (
Expand Down Expand Up @@ -139,6 +140,7 @@ func init() {
startCmd.Flags().String(vpnkitSock, "", "Location of the VPNKit socket used for networking. If empty, disables Hyperkit VPNKitSock, if 'auto' uses Docker for Mac VPNKit connection, otherwise uses the specified VSock.")
startCmd.Flags().StringSlice(vsockPorts, []string{}, "List of guest VSock ports that should be exposed as sockets on the host (Only supported on with hyperkit now).")
startCmd.Flags().Bool(gpu, false, "Enable experimental NVIDIA GPU support in minikube (works only with kvm2 driver on Linux)")
startCmd.Flags().Bool(noVTXCheck, false, "Disable checking for the availability of hardware virtualization before the vm is started (virtualbox)")
viper.BindPFlags(startCmd.Flags())
RootCmd.AddCommand(startCmd)
}
Expand Down Expand Up @@ -282,6 +284,7 @@ func generateConfig(cmd *cobra.Command, kVersion string) (cfg.Config, error) {
DisableDriverMounts: viper.GetBool(disableDriverMounts),
UUID: viper.GetString(uuid),
GPU: viper.GetBool(gpu),
NoVTXCheck: viper.GetBool(noVTXCheck),
},
KubernetesConfig: cfg.KubernetesConfig{
KubernetesVersion: kVersion,
Expand Down
1 change: 1 addition & 0 deletions pkg/minikube/config/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ type MachineConfig struct {
NFSSharesRoot string
UUID string // Only used by hyperkit to restore the mac address
GPU bool // Only used by kvm2
NoVTXCheck bool // Only used by virtualbox
}

// KubernetesConfig contains the parameters used to configure the VM Kubernetes.
Expand Down
1 change: 1 addition & 0 deletions pkg/minikube/drivers/virtualbox/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ func createVirtualboxHost(config cfg.MachineConfig) interface{} {
d.DiskSize = int(config.DiskSize)
d.HostOnlyCIDR = config.HostOnlyCIDR
d.NoShare = config.DisableDriverMounts
d.NoVTXCheck = config.NoVTXCheck
d.NatNicType = defaultVirtualboxNicType
d.HostOnlyNicType = defaultVirtualboxNicType
d.DNSProxy = false
Expand Down

0 comments on commit 185570b

Please sign in to comment.