From 46e9cc24ee05f2e520f7f5d8667d33e21d81e617 Mon Sep 17 00:00:00 2001 From: Steven Powell Date: Tue, 24 Jan 2023 11:51:17 -0800 Subject: [PATCH 1/4] check brew install paths for socket_vmnet --- cmd/minikube/cmd/start_flags.go | 8 +++---- pkg/drivers/qemu/qemu.go | 6 +++--- pkg/minikube/detect/detect.go | 38 +++++++++++++++++++++++++++++++-- 3 files changed, 43 insertions(+), 9 deletions(-) diff --git a/cmd/minikube/cmd/start_flags.go b/cmd/minikube/cmd/start_flags.go index aea0a1752040..77b024a34771 100644 --- a/cmd/minikube/cmd/start_flags.go +++ b/cmd/minikube/cmd/start_flags.go @@ -281,8 +281,8 @@ func initNetworkingFlags() { startCmd.Flags().Int(sshSSHPort, defaultSSHPort, "SSH port (ssh driver only)") // socket vmnet - startCmd.Flags().String(socketVMnetClientPath, "/opt/socket_vmnet/bin/socket_vmnet_client", "Path to the socket vmnet client binary") - startCmd.Flags().String(socketVMnetPath, "/var/run/socket_vmnet", "Path to socket vmnet binary") + startCmd.Flags().String(socketVMnetClientPath, "", "Path to the socket vmnet client binary") + startCmd.Flags().String(socketVMnetPath, "", "Path to socket vmnet binary") } // ClusterFlagValue returns the current cluster name based on flags @@ -571,8 +571,8 @@ func generateNewConfigFromFlags(cmd *cobra.Command, k8sVersion string, rtime str DisableOptimizations: viper.GetBool(disableOptimizations), DisableMetrics: viper.GetBool(disableMetrics), CustomQemuFirmwarePath: viper.GetString(qemuFirmwarePath), - SocketVMnetClientPath: viper.GetString(socketVMnetClientPath), - SocketVMnetPath: viper.GetString(socketVMnetPath), + SocketVMnetClientPath: detect.SocketVMNetClientPath(), + SocketVMnetPath: detect.SocketVMNetPath(), StaticIP: viper.GetString(staticIP), KubernetesConfig: config.KubernetesConfig{ KubernetesVersion: k8sVersion, diff --git a/pkg/drivers/qemu/qemu.go b/pkg/drivers/qemu/qemu.go index 02489ccb7923..add9e8b307cd 100644 --- a/pkg/drivers/qemu/qemu.go +++ b/pkg/drivers/qemu/qemu.go @@ -38,9 +38,9 @@ import ( "github.com/docker/machine/libmachine/ssh" "github.com/docker/machine/libmachine/state" "github.com/pkg/errors" - "github.com/spf13/viper" pkgdrivers "k8s.io/minikube/pkg/drivers" + "k8s.io/minikube/pkg/minikube/detect" ) const ( @@ -447,8 +447,8 @@ func (d *Driver) Start() error { // If socket network, start with socket_vmnet. startProgram := d.Program if d.Network == "socket_vmnet" { - startProgram = viper.GetString("socket-vmnet-client-path") - socketVMnetPath := viper.GetString("socket-vmnet-path") + startProgram = detect.SocketVMNetClientPath() + socketVMnetPath := detect.SocketVMNetPath() startCmd = append([]string{socketVMnetPath, d.Program}, startCmd...) } diff --git a/pkg/minikube/detect/detect.go b/pkg/minikube/detect/detect.go index 0c4ec9c2d0fb..32ace8afc7e0 100644 --- a/pkg/minikube/detect/detect.go +++ b/pkg/minikube/detect/detect.go @@ -140,12 +140,46 @@ func SocketVMNetInstalled() bool { if runtime.GOOS != "darwin" { return false } - _, err := os.Stat(viper.GetString("socket-vmnet-path")) + return SocketVMNetPath() != "" && SocketVMNetClientPath() != "" +} + +// SocketVMNetPath returns the path of socket_vmnet +func SocketVMNetPath() string { + return checkSocketVMnetInstallLocations("socket-vmnet-path", "/var/run/socket_vmnet") +} + +// SocketVMNetClientPath returns the path of socket_vmnet_client +func SocketVMNetClientPath() string { + return checkSocketVMnetInstallLocations("socket-vmnet-client-path", "/opt/socket_vmnet/bin/socket_vmnet_client") +} + +// checkSocketVMnetInstallLocations accepts a flag name and relative file path +// if the flag value is non-empty, returns the flag value +// otherwise, checks the three possible socket_vmnet install locations for the binary +// if the binary is found it returns the full path, otherwise if returns an empty string +func checkSocketVMnetInstallLocations(flagName, path string) string { + p := viper.GetString(flagName) + if p != "" { + return p + } + // source install, arm64 brew install, amd64 brew install + prefixes := []string{"", "/opt/homebrew", "/usr/local"} + for _, prefix := range prefixes { + fullPath := prefix + path + if fileExists(fullPath) { + return fullPath + } + } + return "" +} + +func fileExists(filePath string) bool { + _, err := os.Stat(filePath) if err == nil { return true } if !errors.Is(err, os.ErrNotExist) { - klog.Warningf("failed to check for socket_vmnet: %v", err) + klog.Warningf("failed to check for existance of %s: %v", filePath, err) } return false } From c248182197bcea69208310eb35a2993fed83896b Mon Sep 17 00:00:00 2001 From: Steven Powell Date: Tue, 24 Jan 2023 12:03:40 -0800 Subject: [PATCH 2/4] fix typo --- pkg/minikube/detect/detect.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/minikube/detect/detect.go b/pkg/minikube/detect/detect.go index 32ace8afc7e0..dc4c6155a0b9 100644 --- a/pkg/minikube/detect/detect.go +++ b/pkg/minikube/detect/detect.go @@ -179,7 +179,7 @@ func fileExists(filePath string) bool { return true } if !errors.Is(err, os.ErrNotExist) { - klog.Warningf("failed to check for existance of %s: %v", filePath, err) + klog.Warningf("failed to check for existence of %s: %v", filePath, err) } return false } From 0fbb9a6a3114667ddad996d9da015f565c9586c6 Mon Sep 17 00:00:00 2001 From: Steven Powell Date: Wed, 25 Jan 2023 10:45:20 -0800 Subject: [PATCH 3/4] update comments and store socket_vmnet paths in machine config --- cmd/minikube/cmd/start_flags.go | 4 +- pkg/drivers/qemu/qemu.go | 56 +++++++++++------------ pkg/minikube/detect/detect.go | 27 ++++++----- pkg/minikube/registry/drvs/qemu2/qemu2.go | 36 ++++++++------- site/content/en/docs/commands/start.md | 4 +- translations/de.json | 4 +- translations/es.json | 4 +- translations/fr.json | 2 + translations/ja.json | 2 + translations/ko.json | 4 +- translations/pl.json | 4 +- translations/ru.json | 4 +- translations/strings.txt | 4 +- translations/zh-CN.json | 4 +- 14 files changed, 84 insertions(+), 75 deletions(-) diff --git a/cmd/minikube/cmd/start_flags.go b/cmd/minikube/cmd/start_flags.go index 77b024a34771..3f64f04f7bdf 100644 --- a/cmd/minikube/cmd/start_flags.go +++ b/cmd/minikube/cmd/start_flags.go @@ -281,8 +281,8 @@ func initNetworkingFlags() { startCmd.Flags().Int(sshSSHPort, defaultSSHPort, "SSH port (ssh driver only)") // socket vmnet - startCmd.Flags().String(socketVMnetClientPath, "", "Path to the socket vmnet client binary") - startCmd.Flags().String(socketVMnetPath, "", "Path to socket vmnet binary") + startCmd.Flags().String(socketVMnetClientPath, "", "Path to the socket vmnet client binary (QEMU driver only)") + startCmd.Flags().String(socketVMnetPath, "", "Path to socket vmnet binary (QEMU driver only)") } // ClusterFlagValue returns the current cluster name based on flags diff --git a/pkg/drivers/qemu/qemu.go b/pkg/drivers/qemu/qemu.go index add9e8b307cd..730be5806c5d 100644 --- a/pkg/drivers/qemu/qemu.go +++ b/pkg/drivers/qemu/qemu.go @@ -40,7 +40,6 @@ import ( "github.com/pkg/errors" pkgdrivers "k8s.io/minikube/pkg/drivers" - "k8s.io/minikube/pkg/minikube/detect" ) const ( @@ -56,30 +55,32 @@ type Driver struct { EnginePort int FirstQuery bool - Memory int - DiskSize int - CPU int - Program string - BIOS bool - CPUType string - MachineType string - Firmware string - Display bool - DisplayType string - Nographic bool - VirtioDrives bool - Network string - PrivateNetwork string - Boot2DockerURL string - CaCertPath string - PrivateKeyPath string - DiskPath string - CacheMode string - IOMode string - UserDataFile string - CloudConfigRoot string - LocalPorts string - MACAddress string + Memory int + DiskSize int + CPU int + Program string + BIOS bool + CPUType string + MachineType string + Firmware string + Display bool + DisplayType string + Nographic bool + VirtioDrives bool + Network string + PrivateNetwork string + Boot2DockerURL string + CaCertPath string + PrivateKeyPath string + DiskPath string + CacheMode string + IOMode string + UserDataFile string + CloudConfigRoot string + LocalPorts string + MACAddress string + SocketVMNetPath string + SocketVMNetClientPath string } func (d *Driver) GetMachineName() string { @@ -447,9 +448,8 @@ func (d *Driver) Start() error { // If socket network, start with socket_vmnet. startProgram := d.Program if d.Network == "socket_vmnet" { - startProgram = detect.SocketVMNetClientPath() - socketVMnetPath := detect.SocketVMNetPath() - startCmd = append([]string{socketVMnetPath, d.Program}, startCmd...) + startProgram = d.SocketVMNetClientPath + startCmd = append([]string{d.SocketVMNetPath, d.Program}, startCmd...) } if stdout, stderr, err := cmdOutErr(startProgram, startCmd...); err != nil { diff --git a/pkg/minikube/detect/detect.go b/pkg/minikube/detect/detect.go index dc4c6155a0b9..ceaf350131a3 100644 --- a/pkg/minikube/detect/detect.go +++ b/pkg/minikube/detect/detect.go @@ -143,25 +143,28 @@ func SocketVMNetInstalled() bool { return SocketVMNetPath() != "" && SocketVMNetClientPath() != "" } -// SocketVMNetPath returns the path of socket_vmnet +// SocketVMNetPath returns the path of socket_vmnet (QEMU driver only) func SocketVMNetPath() string { - return checkSocketVMnetInstallLocations("socket-vmnet-path", "/var/run/socket_vmnet") + p := viper.GetString("socket-vmnet-path") + if p != "" { + return p + } + return checkSocketVMNetInstallLocations("/var/run/socket_vmnet") } -// SocketVMNetClientPath returns the path of socket_vmnet_client +// SocketVMNetClientPath returns the path of socket_vmnet_client (QEMU driver only) func SocketVMNetClientPath() string { - return checkSocketVMnetInstallLocations("socket-vmnet-client-path", "/opt/socket_vmnet/bin/socket_vmnet_client") -} - -// checkSocketVMnetInstallLocations accepts a flag name and relative file path -// if the flag value is non-empty, returns the flag value -// otherwise, checks the three possible socket_vmnet install locations for the binary -// if the binary is found it returns the full path, otherwise if returns an empty string -func checkSocketVMnetInstallLocations(flagName, path string) string { - p := viper.GetString(flagName) + p := viper.GetString("socket-vmnet-client-path") if p != "" { return p } + return checkSocketVMNetInstallLocations("/opt/socket_vmnet/bin/socket_vmnet_client") +} + +// checkSocketVMNetInstallLocations accepts a relative file path +// checks the three possible socket_vmnet install locations for existance of the file path +// if the file path exists it returns the full path, otherwise if returns an empty string +func checkSocketVMNetInstallLocations(path string) string { // source install, arm64 brew install, amd64 brew install prefixes := []string{"", "/opt/homebrew", "/usr/local"} for _, prefix := range prefixes { diff --git a/pkg/minikube/registry/drvs/qemu2/qemu2.go b/pkg/minikube/registry/drvs/qemu2/qemu2.go index cb16192d0890..f2e0e0c106f7 100644 --- a/pkg/minikube/registry/drvs/qemu2/qemu2.go +++ b/pkg/minikube/registry/drvs/qemu2/qemu2.go @@ -170,23 +170,25 @@ func configure(cc config.ClusterConfig, n config.Node) (interface{}, error) { StorePath: localpath.MiniPath(), SSHUser: "docker", }, - Boot2DockerURL: download.LocalISOResource(cc.MinikubeISO), - DiskSize: cc.DiskSize, - Memory: cc.Memory, - CPU: cc.CPUs, - EnginePort: 2376, - FirstQuery: true, - DiskPath: filepath.Join(localpath.MiniPath(), "machines", name, fmt.Sprintf("%s.img", name)), - Program: qemuSystem, - BIOS: runtime.GOARCH != "arm64", - MachineType: qemuMachine, - CPUType: qemuCPU, - Firmware: qemuFirmware, - VirtioDrives: false, - Network: cc.Network, - CacheMode: "default", - IOMode: "threads", - MACAddress: mac, + Boot2DockerURL: download.LocalISOResource(cc.MinikubeISO), + DiskSize: cc.DiskSize, + Memory: cc.Memory, + CPU: cc.CPUs, + EnginePort: 2376, + FirstQuery: true, + DiskPath: filepath.Join(localpath.MiniPath(), "machines", name, fmt.Sprintf("%s.img", name)), + Program: qemuSystem, + BIOS: runtime.GOARCH != "arm64", + MachineType: qemuMachine, + CPUType: qemuCPU, + Firmware: qemuFirmware, + VirtioDrives: false, + Network: cc.Network, + CacheMode: "default", + IOMode: "threads", + MACAddress: mac, + SocketVMNetPath: cc.SocketVMnetPath, + SocketVMNetClientPath: cc.SocketVMnetClientPath, }, nil } diff --git a/site/content/en/docs/commands/start.md b/site/content/en/docs/commands/start.md index 3978fcaa6877..97c206e55307 100644 --- a/site/content/en/docs/commands/start.md +++ b/site/content/en/docs/commands/start.md @@ -105,8 +105,8 @@ minikube start [flags] --qemu-firmware-path string Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\Program Files\qemu\share --registry-mirror strings Registry mirrors to pass to the Docker daemon --service-cluster-ip-range string The CIDR to be used for service cluster IPs. (default "10.96.0.0/12") - --socket-vmnet-client-path string Path to the socket vmnet client binary (default "/opt/socket_vmnet/bin/socket_vmnet_client") - --socket-vmnet-path string Path to socket vmnet binary (default "/var/run/socket_vmnet") + --socket-vmnet-client-path string Path to the socket vmnet client binary (QEMU driver only) + --socket-vmnet-path string Path to socket vmnet binary (QEMU driver only) --ssh-ip-address string IP address (ssh driver only) --ssh-key string SSH key (ssh driver only) --ssh-port int SSH port (ssh driver only) (default 22) diff --git a/translations/de.json b/translations/de.json index c8ede36b6362..c46535105ad3 100644 --- a/translations/de.json +++ b/translations/de.json @@ -470,10 +470,10 @@ "Outputs minikube shell completion for the given shell (bash, zsh or fish)\n\n\tThis depends on the bash-completion binary. Example installation instructions:\n\tOS X:\n\t\t$ brew install bash-completion\n\t\t$ source $(brew --prefix)/etc/bash_completion\n\t\t$ minikube completion bash \u003e ~/.minikube-completion # for bash users\n\t\t$ minikube completion zsh \u003e ~/.minikube-completion # for zsh users\n\t\t$ source ~/.minikube-completion\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\tUbuntu:\n\t\t$ apt-get install bash-completion\n\t\t$ source /etc/bash_completion\n\t\t$ source \u003c(minikube completion bash) # for bash users\n\t\t$ source \u003c(minikube completion zsh) # for zsh users\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\n\tAdditionally, you may want to output the completion to a file and source in your .bashrc\n\n\tNote for zsh users: [1] zsh completions are only supported in versions of zsh \u003e= 5.2\n\tNote for fish users: [2] please refer to this docs for more details https://fishshell.com/docs/current/#tab-completion\n": "", "Outputs the licenses of dependencies to a directory": "", "Overwrite image even if same image:tag name exists": "Überschreibe das Image, auch wenn ein Image mit dem gleichen Image:Tag-Namen existiert", - "Path to socket vmnet binary": "", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "Pfad des zu verwendenden Dockerfiles (optional)", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "", - "Path to the socket vmnet client binary": "", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "", "Paused {{.count}} containers": "{{.count}} Container pausiert", "Paused {{.count}} containers in: {{.namespaces}}": "{{.count}} Container pausiert in: {{.namespaces}}", diff --git a/translations/es.json b/translations/es.json index 192bce3e18ad..7f152b7e8209 100644 --- a/translations/es.json +++ b/translations/es.json @@ -477,10 +477,10 @@ "Outputs minikube shell completion for the given shell (bash, zsh or fish)\n\n\tThis depends on the bash-completion binary. Example installation instructions:\n\tOS X:\n\t\t$ brew install bash-completion\n\t\t$ source $(brew --prefix)/etc/bash_completion\n\t\t$ minikube completion bash \u003e ~/.minikube-completion # for bash users\n\t\t$ minikube completion zsh \u003e ~/.minikube-completion # for zsh users\n\t\t$ source ~/.minikube-completion\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\tUbuntu:\n\t\t$ apt-get install bash-completion\n\t\t$ source /etc/bash_completion\n\t\t$ source \u003c(minikube completion bash) # for bash users\n\t\t$ source \u003c(minikube completion zsh) # for zsh users\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\n\tAdditionally, you may want to output the completion to a file and source in your .bashrc\n\n\tNote for zsh users: [1] zsh completions are only supported in versions of zsh \u003e= 5.2\n\tNote for fish users: [2] please refer to this docs for more details https://fishshell.com/docs/current/#tab-completion\n": "", "Outputs the licenses of dependencies to a directory": "", "Overwrite image even if same image:tag name exists": "", - "Path to socket vmnet binary": "", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "", - "Path to the socket vmnet client binary": "", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "", "Paused {{.count}} containers": "", "Paused {{.count}} containers in: {{.namespaces}}": "", diff --git a/translations/fr.json b/translations/fr.json index b16a247e633c..c6d4da9de97c 100644 --- a/translations/fr.json +++ b/translations/fr.json @@ -458,9 +458,11 @@ "Outputs the licenses of dependencies to a directory": "Copie les licences des dépendances dans un répertoire", "Overwrite image even if same image:tag name exists": "Écraser l'image même si la même image:balise existe", "Path to socket vmnet binary": "Chemin d'accès au binaire socket vmnet", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "Chemin d'accès au Dockerfile à utiliser (facultatif)", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "Chemin d'accès au fichier du micrologiciel qemu. Valeurs par défaut : pour Linux, l'emplacement du micrologiciel par défaut. Pour macOS, l'emplacement d'installation de brew. Pour Windows, C:\\Program Files\\qemu\\share", "Path to the socket vmnet client binary": "Chemin d'accès au binaire socket vmnet", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "Pause", "Paused {{.count}} containers": "{{.count}} conteneurs suspendus", "Paused {{.count}} containers in: {{.namespaces}}": "{{.count}} conteneurs suspendus dans : {{.namespaces}}", diff --git a/translations/ja.json b/translations/ja.json index 9aef4bf25d39..3e1543952074 100644 --- a/translations/ja.json +++ b/translations/ja.json @@ -443,9 +443,11 @@ "Outputs the licenses of dependencies to a directory": "依存関係のライセンスをディレクトリーに出力します", "Overwrite image even if same image:tag name exists": "同じ image:tag 名が存在していてもイメージを上書きします", "Path to socket vmnet binary": "socket vmnet バイナリーへのパス", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "使用する Dockerfile へのパス (任意)", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "qemu ファームウェアファイルへのパス。デフォルト: Linux の場合、デフォルトのファームウェアの場所。macOS の場合、brew のインストール場所。Windows の場合、C:\\Program Files\\qemu\\share", "Path to the socket vmnet client binary": "socket vmnet クライアントバイナリーへのパス", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "一時停止", "Paused {{.count}} containers": "{{.count}} 個のコンテナーを一時停止しました", "Paused {{.count}} containers in: {{.namespaces}}": "{{.namespaces}} に存在する {{.count}} 個のコンテナーを一時停止しました", diff --git a/translations/ko.json b/translations/ko.json index 6c95450c120f..7a2eadf9e236 100644 --- a/translations/ko.json +++ b/translations/ko.json @@ -490,10 +490,10 @@ "Outputs minikube shell completion for the given shell (bash, zsh or fish)\n\n\tThis depends on the bash-completion binary. Example installation instructions:\n\tOS X:\n\t\t$ brew install bash-completion\n\t\t$ source $(brew --prefix)/etc/bash_completion\n\t\t$ minikube completion bash \u003e ~/.minikube-completion # for bash users\n\t\t$ minikube completion zsh \u003e ~/.minikube-completion # for zsh users\n\t\t$ source ~/.minikube-completion\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\tUbuntu:\n\t\t$ apt-get install bash-completion\n\t\t$ source /etc/bash_completion\n\t\t$ source \u003c(minikube completion bash) # for bash users\n\t\t$ source \u003c(minikube completion zsh) # for zsh users\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\n\tAdditionally, you may want to output the completion to a file and source in your .bashrc\n\n\tNote for zsh users: [1] zsh completions are only supported in versions of zsh \u003e= 5.2\n\tNote for fish users: [2] please refer to this docs for more details https://fishshell.com/docs/current/#tab-completion\n": "", "Outputs the licenses of dependencies to a directory": "", "Overwrite image even if same image:tag name exists": "", - "Path to socket vmnet binary": "", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "", - "Path to the socket vmnet client binary": "", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "", "Paused {{.count}} containers": "", "Paused {{.count}} containers in: {{.namespaces}}": "", diff --git a/translations/pl.json b/translations/pl.json index ec44eddc9477..9903e1176c57 100644 --- a/translations/pl.json +++ b/translations/pl.json @@ -484,10 +484,10 @@ "Outputs minikube shell completion for the given shell (bash, zsh or fish)\n\n\tThis depends on the bash-completion binary. Example installation instructions:\n\tOS X:\n\t\t$ brew install bash-completion\n\t\t$ source $(brew --prefix)/etc/bash_completion\n\t\t$ minikube completion bash \u003e ~/.minikube-completion # for bash users\n\t\t$ minikube completion zsh \u003e ~/.minikube-completion # for zsh users\n\t\t$ source ~/.minikube-completion\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\tUbuntu:\n\t\t$ apt-get install bash-completion\n\t\t$ source /etc/bash_completion\n\t\t$ source \u003c(minikube completion bash) # for bash users\n\t\t$ source \u003c(minikube completion zsh) # for zsh users\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\n\tAdditionally, you may want to output the completion to a file and source in your .bashrc\n\n\tNote for zsh users: [1] zsh completions are only supported in versions of zsh \u003e= 5.2\n\tNote for fish users: [2] please refer to this docs for more details https://fishshell.com/docs/current/#tab-completion\n": "", "Outputs the licenses of dependencies to a directory": "", "Overwrite image even if same image:tag name exists": "Nadpisuje obraz nawet jeśli istnieje obraz o tej samej nazwie i tagu.", - "Path to socket vmnet binary": "", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "Ścieżka pliku Dockerfile, którego należy użyć (opcjonalne)", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "", - "Path to the socket vmnet client binary": "", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "Stop", "Paused {{.count}} containers": "Zatrzymane kontenery: {{.count}}", "Paused {{.count}} containers in: {{.namespaces}}": "Zatrzymane kontenery: {{.count}} w przestrzeniach nazw: {{.namespaces}}", diff --git a/translations/ru.json b/translations/ru.json index ab9edae34275..dadf477deb5b 100644 --- a/translations/ru.json +++ b/translations/ru.json @@ -440,10 +440,10 @@ "Outputs minikube shell completion for the given shell (bash, zsh or fish)\n\n\tThis depends on the bash-completion binary. Example installation instructions:\n\tOS X:\n\t\t$ brew install bash-completion\n\t\t$ source $(brew --prefix)/etc/bash_completion\n\t\t$ minikube completion bash \u003e ~/.minikube-completion # for bash users\n\t\t$ minikube completion zsh \u003e ~/.minikube-completion # for zsh users\n\t\t$ source ~/.minikube-completion\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\tUbuntu:\n\t\t$ apt-get install bash-completion\n\t\t$ source /etc/bash_completion\n\t\t$ source \u003c(minikube completion bash) # for bash users\n\t\t$ source \u003c(minikube completion zsh) # for zsh users\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\n\tAdditionally, you may want to output the completion to a file and source in your .bashrc\n\n\tNote for zsh users: [1] zsh completions are only supported in versions of zsh \u003e= 5.2\n\tNote for fish users: [2] please refer to this docs for more details https://fishshell.com/docs/current/#tab-completion\n": "", "Outputs the licenses of dependencies to a directory": "", "Overwrite image even if same image:tag name exists": "", - "Path to socket vmnet binary": "", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "", - "Path to the socket vmnet client binary": "", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "", "Paused {{.count}} containers": "", "Paused {{.count}} containers in: {{.namespaces}}": "", diff --git a/translations/strings.txt b/translations/strings.txt index 0cd322d4321b..8042095ea626 100644 --- a/translations/strings.txt +++ b/translations/strings.txt @@ -440,10 +440,10 @@ "Outputs minikube shell completion for the given shell (bash, zsh or fish)\n\n\tThis depends on the bash-completion binary. Example installation instructions:\n\tOS X:\n\t\t$ brew install bash-completion\n\t\t$ source $(brew --prefix)/etc/bash_completion\n\t\t$ minikube completion bash \u003e ~/.minikube-completion # for bash users\n\t\t$ minikube completion zsh \u003e ~/.minikube-completion # for zsh users\n\t\t$ source ~/.minikube-completion\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\tUbuntu:\n\t\t$ apt-get install bash-completion\n\t\t$ source /etc/bash_completion\n\t\t$ source \u003c(minikube completion bash) # for bash users\n\t\t$ source \u003c(minikube completion zsh) # for zsh users\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\n\tAdditionally, you may want to output the completion to a file and source in your .bashrc\n\n\tNote for zsh users: [1] zsh completions are only supported in versions of zsh \u003e= 5.2\n\tNote for fish users: [2] please refer to this docs for more details https://fishshell.com/docs/current/#tab-completion\n": "", "Outputs the licenses of dependencies to a directory": "", "Overwrite image even if same image:tag name exists": "", - "Path to socket vmnet binary": "", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "", - "Path to the socket vmnet client binary": "", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "", "Paused {{.count}} containers": "", "Paused {{.count}} containers in: {{.namespaces}}": "", diff --git a/translations/zh-CN.json b/translations/zh-CN.json index d717e0566f18..700c82482bd6 100644 --- a/translations/zh-CN.json +++ b/translations/zh-CN.json @@ -557,10 +557,10 @@ "Outputs minikube shell completion for the given shell (bash, zsh or fish)\n\n\tThis depends on the bash-completion binary. Example installation instructions:\n\tOS X:\n\t\t$ brew install bash-completion\n\t\t$ source $(brew --prefix)/etc/bash_completion\n\t\t$ minikube completion bash \u003e ~/.minikube-completion # for bash users\n\t\t$ minikube completion zsh \u003e ~/.minikube-completion # for zsh users\n\t\t$ source ~/.minikube-completion\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\tUbuntu:\n\t\t$ apt-get install bash-completion\n\t\t$ source /etc/bash_completion\n\t\t$ source \u003c(minikube completion bash) # for bash users\n\t\t$ source \u003c(minikube completion zsh) # for zsh users\n\t\t$ minikube completion fish \u003e ~/.config/fish/completions/minikube.fish # for fish users\n\n\tAdditionally, you may want to output the completion to a file and source in your .bashrc\n\n\tNote for zsh users: [1] zsh completions are only supported in versions of zsh \u003e= 5.2\n\tNote for fish users: [2] please refer to this docs for more details https://fishshell.com/docs/current/#tab-completion\n": "", "Outputs the licenses of dependencies to a directory": "", "Overwrite image even if same image:tag name exists": "", - "Path to socket vmnet binary": "", + "Path to socket vmnet binary (QEMU driver only)": "", "Path to the Dockerfile to use (optional)": "", "Path to the qemu firmware file. Defaults: For Linux, the default firmware location. For macOS, the brew installation location. For Windows, C:\\Program Files\\qemu\\share": "", - "Path to the socket vmnet client binary": "", + "Path to the socket vmnet client binary (QEMU driver only)": "", "Pause": "暂停", "Paused kubelet and {{.count}} containers": "已暂停 kubelet 和 {{.count}} 个容器", "Paused kubelet and {{.count}} containers in: {{.namespaces}}": "已暂停 {{.namespaces}} 中的 kubelet 和 {{.count}} 个容器", From 7c1f8491bd161bd38e9e1e75f741199fb4834c9d Mon Sep 17 00:00:00 2001 From: Steven Powell Date: Wed, 25 Jan 2023 10:47:30 -0800 Subject: [PATCH 4/4] typo --- pkg/minikube/detect/detect.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/minikube/detect/detect.go b/pkg/minikube/detect/detect.go index ceaf350131a3..ca98a3781e01 100644 --- a/pkg/minikube/detect/detect.go +++ b/pkg/minikube/detect/detect.go @@ -162,7 +162,7 @@ func SocketVMNetClientPath() string { } // checkSocketVMNetInstallLocations accepts a relative file path -// checks the three possible socket_vmnet install locations for existance of the file path +// checks the three possible socket_vmnet install locations for existence of the file path // if the file path exists it returns the full path, otherwise if returns an empty string func checkSocketVMNetInstallLocations(path string) string { // source install, arm64 brew install, amd64 brew install