Add comment explaining pkg/initflag
parent
7ece838d28
commit
08c86b4010
|
@ -23,6 +23,8 @@ import (
|
|||
"os"
|
||||
"strconv"
|
||||
|
||||
// initflag must be imported before any other minikube pkg.
|
||||
// Fix for https://github.com/kubernetes/minikube/issues/4866
|
||||
_ "k8s.io/minikube/pkg/initflag"
|
||||
|
||||
"github.com/golang/glog"
|
||||
|
|
|
@ -21,8 +21,9 @@ import (
|
|||
)
|
||||
|
||||
func init() {
|
||||
// Workaround for "ERROR: logging before flag.Parse"
|
||||
// See: https://github.com/kubernetes/kubernetes/issues/17162
|
||||
fs := flag.NewFlagSet("", flag.ContinueOnError)
|
||||
|
||||
_ = fs.Parse([]string{})
|
||||
flag.CommandLine = fs
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue