Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 27 for RestartPolicyNever (0.58 sec)

  1. pkg/apis/apps/validation/validation_test.go

    			field.NotSupported[string](field.NewPath("spec", "template", "spec", "restartPolicy"), nil, nil),
    		},
    	}, {
    		name: "invalid restart policy 2",
    		set:  mkStatefulSet(&validPodTemplate, tweakTemplateRestartPolicy(api.RestartPolicyNever)),
    		errs: field.ErrorList{
    			field.NotSupported[string](field.NewPath("spec", "template", "spec", "restartPolicy"), nil, nil),
    		},
    	}, {
    		name: "empty restart policy",
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 111.9K bytes
    - Viewed (0)
  2. pkg/kubelet/container/helpers_test.go

    				State: ContainerStateUnknown,
    			},
    			{
    				Name:     "failed",
    				State:    ContainerStateExited,
    				ExitCode: 3,
    			},
    		},
    	}
    	policies := []v1.RestartPolicy{
    		v1.RestartPolicyNever,
    		v1.RestartPolicyOnFailure,
    		v1.RestartPolicyAlways,
    	}
    
    	// test policies
    	expected := map[string][]bool{
    		"no-history": {true, true, true},
    		"alive":      {false, false, false},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 22 01:55:46 UTC 2024
    - 24.5K bytes
    - Viewed (0)
  3. pkg/api/pod/util_test.go

    	procMount := api.UnmaskedProcMount
    	defaultProcMount := api.DefaultProcMount
    	podWithProcMount := func() *api.Pod {
    		return &api.Pod{
    			Spec: api.PodSpec{
    				RestartPolicy:  api.RestartPolicyNever,
    				Containers:     []api.Container{{Name: "container1", Image: "testimage", SecurityContext: &api.SecurityContext{ProcMount: &procMount}}},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 29 22:40:29 UTC 2024
    - 108.8K bytes
    - Viewed (0)
  4. pkg/registry/batch/job/strategy_test.go

    		},
    	}
    	validPodTemplateSpecNever := *validPodTemplateSpec.DeepCopy()
    	validPodTemplateSpecNever.Spec.RestartPolicy = api.RestartPolicyNever
    	now := metav1.Now()
    	cases := map[string]struct {
    		enableJobPodFailurePolicy     bool
    		enableJobBackoffLimitPerIndex bool
    		job                           *batch.Job
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 101.5K bytes
    - Viewed (0)
  5. pkg/controller/endpoint/endpoints_controller_test.go

    			Labels: map[string]string{
    				"foo": "bar",
    			},
    		},
    		Subsets: []v1.EndpointSubset{},
    	})
    	addNotReadyPodsWithSpecifiedRestartPolicyAndPhase(endpoints.podStore, ns, 1, 1, v1.RestartPolicyNever, v1.PodFailed)
    	endpoints.serviceStore.Add(&v1.Service{
    		ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: ns},
    		Spec: v1.ServiceSpec{
    			Selector: map[string]string{"foo": "bar"},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Feb 26 06:51:56 UTC 2024
    - 87.7K bytes
    - Viewed (0)
  6. pkg/volume/plugins.go

    		ObjectMeta: metav1.ObjectMeta{
    			GenerateName: "pv-recycler-",
    			Namespace:    metav1.NamespaceDefault,
    		},
    		Spec: v1.PodSpec{
    			ActiveDeadlineSeconds: &timeout,
    			RestartPolicy:         v1.RestartPolicyNever,
    			Volumes: []v1.Volume{
    				{
    					Name: "vol",
    					// IMPORTANT!  All plugins using this template MUST
    					// override pod.Spec.Volumes[0].VolumeSource Recycler
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Jun 06 16:13:15 UTC 2024
    - 38.2K bytes
    - Viewed (0)
  7. pkg/kubelet/kubelet_pods_test.go

    	desiredState := v1.PodSpec{
    		NodeName: "machine",
    		Containers: []v1.Container{
    			{Name: "containerA"},
    			{Name: "containerB"},
    		},
    		RestartPolicy: v1.RestartPolicyNever,
    	}
    
    	tests := []struct {
    		pod    *v1.Pod
    		status v1.PodPhase
    		test   string
    	}{
    		{&v1.Pod{Spec: desiredState, Status: v1.PodStatus{}}, v1.PodPending, "waiting"},
    		{
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 07 00:05:23 UTC 2024
    - 198.8K bytes
    - Viewed (0)
  8. pkg/apis/batch/validation/validation_test.go

    	validPodTemplateSpecForGeneratedRestartPolicyNever := getValidPodTemplateSpecForGenerated(validGeneratedSelector)
    	validPodTemplateSpecForGeneratedRestartPolicyNever.Spec.RestartPolicy = api.RestartPolicyNever
    	validHostNetPodTemplateSpec := func() api.PodTemplateSpec {
    		spec := getValidPodTemplateSpecForGenerated(validGeneratedSelector)
    		spec.Spec.SecurityContext = &api.PodSecurityContext{
    			HostNetwork: true,
    		}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 20:49:09 UTC 2024
    - 124.3K bytes
    - Viewed (0)
  9. pkg/kubelet/kubelet_pods.go

    				stopped++
    			} else {
    				waiting++
    			}
    		default:
    			unknown++
    		}
    	}
    
    	if failedInitialization > 0 && spec.RestartPolicy == v1.RestartPolicyNever {
    		return v1.PodFailed
    	}
    
    	switch {
    	case pendingInitialization > 0 &&
    		// This is needed to handle the case where the pod has been initialized but
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 14 16:09:17 UTC 2024
    - 101.2K bytes
    - Viewed (0)
  10. pkg/apis/core/validation/validation.go

    	switch *restartPolicy {
    	case core.RestartPolicyAlways, core.RestartPolicyOnFailure, core.RestartPolicyNever:
    		break
    	case "":
    		allErrors = append(allErrors, field.Required(fldPath, ""))
    	default:
    		validValues := []core.RestartPolicy{core.RestartPolicyAlways, core.RestartPolicyOnFailure, core.RestartPolicyNever}
    		allErrors = append(allErrors, field.NotSupported(fldPath, *restartPolicy, validValues))
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 29 22:40:29 UTC 2024
    - 349.5K bytes
    - Viewed (0)
Back to top