Separate cached kubernetes binaries by OS on host machine
This way, all kubernetes binaries stored in ~/.minikube/cache/linux will be copied over to the VM and used for `minikube kubectl` on linux machines. kubectl will be stored in `~/.minikube/cache/{windows or darwin}` on windows/darwin so that `minikube kubectl` still works.pull/6586/head
parent
ff763db1e7
commit
c04a0c55d6
pkg/minikube/machine
|
@ -21,6 +21,7 @@ import (
|
|||
"fmt"
|
||||
"os"
|
||||
"path"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
|
||||
"github.com/golang/glog"
|
||||
|
@ -63,7 +64,7 @@ func KubernetesReleaseURLSHA1(binaryName, version, osName, archName string) stri
|
|||
|
||||
// CacheBinary will cache a binary on the host
|
||||
func CacheBinary(binary, version, osName, archName string) (string, error) {
|
||||
targetDir := localpath.MakeMiniPath("cache", version)
|
||||
targetDir := localpath.MakeMiniPath(filepath.Join("cache", osName), version)
|
||||
targetFilepath := path.Join(targetDir, binary)
|
||||
|
||||
url := KubernetesReleaseURL(binary, version, osName, archName)
|
||||
|
|
Loading…
Reference in New Issue