Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for ParseConfig (0.09 sec)

  1. cni/pkg/plugin/plugin_test.go

    	}
    }
    
    func testCmdAddExpectFail(t *testing.T, stdinData string, objects ...runtime.Object) *mockInterceptRuleMgr {
    	args := buildCmdArgs(stdinData, testPodName, testNSName)
    
    	conf, err := parseConfig(args.StdinData)
    	if err != nil {
    		t.Fatalf("config parse failed with error: %v", err)
    	}
    
    	// Create a kube client
    	client := kube.NewFakeClient(objects...)
    
    	mockRedir := &mockInterceptRuleMgr{}
    Registered: Wed Nov 06 22:53:10 UTC 2024
    - Last Modified: Wed Oct 09 16:05:45 UTC 2024
    - 17.3K bytes
    - Viewed (0)
  2. cmd/bucket-metadata.go

    		b.versioningConfig, err = versioning.ParseConfig(bytes.NewReader(b.VersioningConfigXML))
    		if err != nil {
    			return err
    		}
    	}
    
    	if len(b.QuotaConfigJSON) != 0 {
    		b.quotaConfig, err = parseBucketQuota(b.Name, b.QuotaConfigJSON)
    		if err != nil {
    			return err
    		}
    	}
    
    	if len(b.ReplicationConfigXML) != 0 {
    		b.replicationConfig, err = replication.ParseConfig(bytes.NewReader(b.ReplicationConfigXML))
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Aug 28 15:32:18 UTC 2024
    - 18.2K bytes
    - Viewed (0)
  3. cni/pkg/plugin/plugin_dryrun_test.go

    }
    
    func testdoAddRunWithIptablesIntercept(t *testing.T, stdinData, testPodName, testNSName string, objects ...runtime.Object) {
    	args := buildCmdArgs(stdinData, testPodName, testNSName)
    
    	conf, err := parseConfig(args.StdinData)
    	if err != nil {
    		t.Fatalf("config parse failed with error: %v", err)
    	}
    
    	// Create a kube client
    	client := kube.NewFakeClient(objects...)
    
    Registered: Wed Nov 06 22:53:10 UTC 2024
    - Last Modified: Tue Aug 27 16:44:45 UTC 2024
    - 8.5K bytes
    - Viewed (0)
  4. cmd/admin-bucket-handlers.go

    		if fileName == bucketVersioningConfig {
    			reader, err := file.Open()
    			if err != nil {
    				rpt.SetStatus(bucket, fileName, err)
    				continue
    			}
    			v, err := versioning.ParseConfig(io.LimitReader(reader, maxBucketVersioningConfigSize))
    			if err != nil {
    				rpt.SetStatus(bucket, fileName, err)
    				continue
    			}
    			if _, ok := bucketMap[bucket]; !ok {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Aug 28 15:32:18 UTC 2024
    - 33.2K bytes
    - Viewed (0)
  5. cmd/iam.go

    	if ptok && spok && pt == embeddedPolicyType {
    		policyBytes, err := base64.StdEncoding.DecodeString(sp)
    		if err != nil {
    			return UserIdentity{}, nil, err
    		}
    		embeddedPolicy, err = policy.ParseConfig(bytes.NewReader(policyBytes))
    		if err != nil {
    			return UserIdentity{}, nil, err
    		}
    	}
    
    	return sa, embeddedPolicy, nil
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Oct 29 16:01:48 UTC 2024
    - 74.6K bytes
    - Viewed (0)
  6. cmd/admin-handlers-users.go

    	}) {
    		writeErrorResponseJSON(ctx, w, errorCodes.ToAPIErr(ErrAccessDenied), r.URL)
    		return
    	}
    
    	var sp *policy.Policy
    	if len(updateReq.NewPolicy) > 0 {
    		sp, err = policy.ParseConfig(bytes.NewReader(updateReq.NewPolicy))
    		if err != nil {
    			writeErrorResponseJSON(ctx, w, toAdminAPIErr(ctx, err), r.URL)
    			return
    		}
    		if sp.Version == "" && len(sp.Statements) == 0 {
    			sp = nil
    		}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Oct 03 23:11:02 UTC 2024
    - 85.1K bytes
    - Viewed (0)
Back to top