- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 23 for initFlags (0.17 sec)
-
cmd/kubeadm/app/kubeadm.go
cliflag "k8s.io/component-base/cli/flag" "k8s.io/klog/v2" "k8s.io/kubernetes/cmd/kubeadm/app/cmd" ) // Run creates and executes new kubeadm command func Run() error { var allFlags flag.FlagSet klog.InitFlags(&allFlags) // only add the flags that are still supported for kubeadm allFlags.VisitAll(func(f *flag.Flag) { switch f.Name { case "v", "add_dir_header", "skip_headers": flag.CommandLine.Var(f.Value, f.Name, f.Usage)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed May 29 04:38:21 UTC 2024 - 1.3K bytes - Viewed (0) -
pkg/log/klog.go
) // KlogVerboseFlag returns verbose flag from the klog library. // After parsing it contains the parsed verbosity value. func klogVerboseFlag() *goflag.Flag { klogFlagSetOnce.Do(func() { klog.InitFlags(klogFlagSet) }) // --v= flag of klog. return klogFlagSet.Lookup("v") } // EnableKlogWithVerbosity sets the klog verbosity directly.
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue May 23 17:08:31 UTC 2023 - 2.1K bytes - Viewed (0) -
staging/src/k8s.io/apimachinery/pkg/util/runtime/runtime_stack_test.go
) //nolint:logcheck // Several functions are normally not okay in a package. func ExampleHandleErrorWithContext() { state := klog.CaptureState() defer state.Restore() var fs flag.FlagSet klog.InitFlags(&fs) for flag, value := range map[string]string{ "one_output": "true", "logtostderr": "false", } { if err := fs.Set(flag, value); err != nil { fmt.Printf("Unexpected error configuring klog: %v", err)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Mar 26 16:28:45 UTC 2024 - 1.9K bytes - Viewed (0) -
cmd/kube-scheduler/app/options/options.go
if leaderelection.Changed("leader-elect-resource-namespace") { cfg.LeaderElection.ResourceNamespace = o.LeaderElection.ResourceNamespace } o.ComponentConfig = cfg } // initFlags initializes flags by section name. func (o *Options) initFlags() { if o.Flags != nil { return } nfs := cliflag.NamedFlagSets{} fs := nfs.FlagSet("misc")
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Jan 17 17:06:29 UTC 2024 - 13.3K bytes - Viewed (0) -
pkg/volume/csi/csi_util_test.go
"k8s.io/klog/v2" "k8s.io/kubernetes/pkg/volume" ) // TestMain starting point for all tests. // Surfaces klog flags by default to enable // go test -v ./ --args <klog flags> func TestMain(m *testing.M) { klog.InitFlags(flag.CommandLine) os.Exit(m.Run()) } func makeTestPVWithMountOptions(name string, sizeGig int, driverName, volID string, mountOptions []string) *api.PersistentVolume { pv := makeTestPV(name, sizeGig, driverName, volID)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jun 20 14:49:03 UTC 2023 - 5.5K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/util/flowcontrol/fairqueuing/testing/promise/counting_test.go
"k8s.io/apiserver/pkg/util/flowcontrol/fairqueuing/promise" testeventclock "k8s.io/apiserver/pkg/util/flowcontrol/fairqueuing/testing/eventclock" "k8s.io/klog/v2" ) func TestMain(m *testing.M) { klog.InitFlags(nil) os.Exit(m.Run()) } func TestCountingWriteOnceSet(t *testing.T) { oldTime := time.Now() cval := &oldTime doneCh := make(chan struct{}) now := time.Now()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Aug 10 14:37:53 UTC 2021 - 4.6K bytes - Viewed (0) -
pkg/controller/volume/ephemeral/controller_test.go
conflictingClaim = makePVC(testPodName+"-"+ephemeralVolumeName, testNamespace, nil) otherNamespaceClaim = makePVC(testPodName+"-"+ephemeralVolumeName, otherNamespace, nil) ) func init() { klog.InitFlags(nil) } func TestSyncHandler(t *testing.T) { tests := []struct { name string podKey string pvcs []*v1.PersistentVolumeClaim pods []*v1.Pod
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Feb 26 06:51:56 UTC 2024 - 8.5K bytes - Viewed (0) -
pkg/kubelet/pluginmanager/pluginwatcher/plugin_watcher_test.go
"k8s.io/kubernetes/pkg/kubelet/pluginmanager/cache" ) var ( supportedVersions = []string{"v1beta1", "v1beta2"} ) func init() { var logLevel string klog.InitFlags(flag.CommandLine) flag.Set("alsologtostderr", fmt.Sprintf("%t", true)) flag.StringVar(&logLevel, "logLevel", "6", "test") flag.Lookup("v").Value.Set(logLevel) } func initTempDir(t *testing.T) string {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Aug 04 06:56:50 UTC 2023 - 8K bytes - Viewed (0) -
cluster/images/etcd/migrate/integration_test.go
testVersionPrevious = &EtcdVersion{semver.MustParse("3.0.17")} testVersionLatest = &EtcdVersion{semver.MustParse("3.1.12")} ) func init() { // Enable klog which is used in dependencies klog.InitFlags(nil) flag.Set("logtostderr", "true") flag.Set("v", "9") } func TestMigrate(t *testing.T) { migrations := []struct { title string memberCount int startVersion string
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Mar 28 07:33:23 UTC 2022 - 11.4K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/value/transformer_test.go
t.Fatal(err) } }) } } func TestLogTransformErr(t *testing.T) { klog.InitFlags(nil) tests := []struct { name string ctx context.Context err error message string expectedLog string }{ { name: "log error with request info",
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jul 18 22:44:02 UTC 2023 - 12.8K bytes - Viewed (0)