Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 68 for admitPV (0.22 sec)

  1. istioctl/pkg/tag/util.go

    import (
    	"context"
    	"fmt"
    
    	"github.com/hashicorp/go-multierror"
    	admitv1 "k8s.io/api/admissionregistration/v1"
    	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
    	"k8s.io/client-go/kubernetes"
    
    	"istio.io/api/label"
    	"istio.io/istio/istioctl/pkg/util"
    )
    
    func GetRevisionWebhooks(ctx context.Context, client kubernetes.Interface) ([]admitv1.MutatingWebhookConfiguration, error) {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Jan 16 17:43:42 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  2. istioctl/pkg/tag/generate_test.go

    			Name:   "istio-sidecar-injector",
    			Labels: map[string]string{label.IoIstioRev.Name: "default"},
    		},
    		Webhooks: []admitv1.MutatingWebhook{
    			{
    				Name: fmt.Sprintf("namespace.%s", istioInjectionWebhookSuffix),
    				ClientConfig: admitv1.WebhookClientConfig{
    					Service: &admitv1.ServiceReference{
    						Namespace: "default",
    						Name:      "istiod",
    					},
    					CABundle: []byte("ca"),
    				},
    			},
    			{
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Jan 16 17:43:49 UTC 2024
    - 12.1K bytes
    - Viewed (0)
  3. istioctl/pkg/tag/tag_test.go

    		tag              string
    		webhooksBefore   admitv1.MutatingWebhookConfigurationList
    		webhooksAfter    admitv1.MutatingWebhookConfigurationList
    		namespaces       corev1.NamespaceList
    		outputMatches    []string
    		skipConfirmation bool
    		error            string
    	}{
    		{
    			name: "TestSimpleRemove",
    			tag:  "sample",
    			webhooksBefore: admitv1.MutatingWebhookConfigurationList{
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri Nov 17 22:41:06 UTC 2023
    - 8.7K bytes
    - Viewed (0)
  4. istioctl/pkg/injector/injector-list.go

    			fmt.Fprintf(w, "%s\t%s\t%s\t%s\n", namespace.Name, hook.Name, revision, injectedImages[revision])
    		}
    	}
    	return w.Flush()
    }
    
    func getInjector(namespace *corev1.Namespace, hooks []admitv1.MutatingWebhookConfiguration) *admitv1.MutatingWebhookConfiguration {
    	// find matching hook
    	for _, hook := range hooks {
    		for _, webhook := range hook.Webhooks {
    			nsSelector, err := metav1.LabelSelectorAsSelector(webhook.NamespaceSelector)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Jan 04 03:08:06 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  5. plugin/pkg/admission/serviceaccount/admission_test.go

    	err := admissiontesting.WithReinvocationTesting(t, admit).Admit(context.TODO(), attrs, nil)
    	if err == nil {
    		t.Errorf("Expected error for missing service account, got none")
    	}
    }
    
    func TestAutomountsAPIToken(t *testing.T) {
    
    	admit := NewServiceAccount()
    	informerFactory := informers.NewSharedInformerFactory(nil, controller.NoResyncPeriodFunc())
    	admit.SetExternalKubeInformerFactory(informerFactory)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Apr 12 17:49:30 UTC 2024
    - 36.9K bytes
    - Viewed (0)
  6. istioctl/pkg/tag/generate.go

    		return nil, err
    	}
    	if vwh == nil {
    		return whConfig, nil
    	}
    	if whConfig.FailurePolicy == nil {
    		whConfig.FailurePolicy = map[string]*admitv1.FailurePolicyType{}
    	}
    	for _, wh := range vwh.Webhooks {
    		if wh.FailurePolicy != nil && *wh.FailurePolicy == admitv1.Fail {
    			whConfig.FailurePolicy[wh.Name] = nil
    		} else {
    			whConfig.FailurePolicy[wh.Name] = wh.FailurePolicy
    		}
    	}
    	return whConfig, nil
    }
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Jan 16 17:43:49 UTC 2024
    - 13.2K bytes
    - Viewed (0)
  7. istioctl/pkg/checkinject/checkinject.go

    				return matched, fmt.Sprintf("%s=%s", me.Key, v)
    			}
    		}
    	}
    	return matched, ""
    }
    
    func extractRevision(wh *admitv1.MutatingWebhookConfiguration) string {
    	return wh.GetLabels()[label.IoIstioRev.Name]
    }
    
    func isIstioWebhook(wh *admitv1.MutatingWebhookConfiguration) bool {
    	for _, w := range wh.Webhooks {
    		if strings.HasSuffix(w.Name, "istio.io") {
    			return true
    		}
    	}
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Sat Apr 13 05:23:38 UTC 2024
    - 9.3K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/admission/metrics/metrics_test.go

    		err := h.(admission.MutationInterface).Admit(context.TODO(), admission.NewAttributesRecord(nil, nil, schema.GroupVersionKind{}, test.ns, "", schema.GroupVersionResource{}, "", test.operation, test.options, false, nil), nil)
    		if test.admit && err != nil {
    			t.Errorf("expected admit to succeed, but failed: %v", err)
    			continue
    		} else if !test.admit && err == nil {
    			t.Errorf("expected admit to fail, but it succeeded")
    			continue
    		}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jul 14 17:01:37 UTC 2023
    - 16.9K bytes
    - Viewed (0)
  9. plugin/pkg/admission/podnodeselector/admission_test.go

    		ignoreTestNamespaceNodeSelector bool
    		admit                           bool
    		testName                        string
    	}{
    		{
    			defaultNodeSelector:             "",
    			podNodeSelector:                 map[string]string{},
    			mergedNodeSelector:              labels.Set{},
    			ignoreTestNamespaceNodeSelector: true,
    			admit:                           true,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Mar 06 00:00:21 UTC 2024
    - 8K bytes
    - Viewed (0)
  10. pkg/kubelet/lifecycle/predicate.go

    		return PodAdmitResult{
    			Admit:   false,
    			Reason:  "PodOSSelectorNodeLabelDoesNotMatch",
    			Message: "Failed to admit pod as the `kubernetes.io/os` label doesn't match node label",
    		}
    	}
    	if rejectPodAdmissionBasedOnOSField(admitPod) {
    		return PodAdmitResult{
    			Admit:   false,
    			Reason:  "PodOSNotSupported",
    			Message: "Failed to admit pod as the OS field doesn't match node OS",
    		}
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Oct 19 00:47:50 UTC 2023
    - 10.9K bytes
    - Viewed (0)
Back to top