diff --git a/pkg/blobfuse-proxy/main.go b/pkg/blobfuse-proxy/main.go index 7d9f4d04e..50ca18960 100644 --- a/pkg/blobfuse-proxy/main.go +++ b/pkg/blobfuse-proxy/main.go @@ -27,16 +27,13 @@ import ( csicommon "sigs.k8s.io/blob-csi-driver/pkg/csi-common" ) -func init() { - _ = flag.Set("logtostderr", "true") -} - var ( blobfuseProxyEndpoint = flag.String("blobfuse-proxy-endpoint", "unix://tmp/blobfuse-proxy.sock", "blobfuse-proxy endpoint") ) func main() { klog.InitFlags(nil) + _ = flag.Set("logtostderr", "true") flag.Parse() proto, addr, err := csicommon.ParseEndpoint(*blobfuseProxyEndpoint) if err != nil { diff --git a/pkg/blobplugin/main.go b/pkg/blobplugin/main.go index 8690778c2..37ca10384 100644 --- a/pkg/blobplugin/main.go +++ b/pkg/blobplugin/main.go @@ -31,10 +31,6 @@ import ( "k8s.io/klog/v2" ) -func init() { - _ = flag.Set("logtostderr", "true") -} - var ( endpoint = flag.String("endpoint", "unix://tmp/csi.sock", "CSI endpoint") blobfuseProxyEndpoint = flag.String("blobfuse-proxy-endpoint", "unix://tmp/blobfuse-proxy.sock", "blobfuse-proxy endpoint") @@ -61,6 +57,7 @@ var ( func main() { klog.InitFlags(nil) + _ = flag.Set("logtostderr", "true") flag.Parse() if *version { info, err := blob.GetVersionYAML(*driverName)