Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 39 for diff (0.12 sec)

  1. operator/cmd/mesh/profile-diff.go

    	return &cobra.Command{
    		Use:   "diff <profile|file1.yaml> <profile|file2.yaml>",
    		Short: "Diffs two Istio configuration profiles",
    		Long:  "The diff subcommand displays the differences between two Istio configuration profiles.",
    		Example: `  # Profile diff by providing yaml files
      istioctl profile diff manifests/profiles/default.yaml manifests/profiles/demo.yaml
    
      # Profile diff by providing a profile name
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Fri Mar 15 01:18:49 GMT 2024
    - 3.1K bytes
    - Viewed (0)
  2. operator/cmd/mesh/manifest-diff.go

    }
    
    func manifestDiffCmd(diffArgs *manifestDiffArgs) *cobra.Command {
    	cmd := &cobra.Command{
    		Use:   "diff <file|dir> <file|dir>",
    		Short: "Compare manifests and generate diff",
    		Long: "The diff subcommand compares manifests from two files or directories. The output is a list of\n" +
    			"changed paths with the value changes shown as OLD-VALUE -> NEW-VALUE.\n" +
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Fri Mar 15 01:18:49 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  3. operator/cmd/mesh/profile-diff_test.go

    func TestProfileDiff(t *testing.T) {
    	cases := []profileDiffTestcase{
    		{
    			args:       "profile diff demo default --unknown-flag",
    			shouldFail: true,
    		},
    		{
    			args:       "profile diff demo",
    			shouldFail: true,
    		},
    		{
    			args:       "profile diff",
    			shouldFail: true,
    		},
    		{
    			args:       fmt.Sprintf("profile diff default unknown-profile --manifests %s", snapshotCharts),
    			shouldFail: true,
    		},
    		{
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Wed Jan 10 05:10:03 GMT 2024
    - 3.6K bytes
    - Viewed (1)
  4. istioctl/pkg/multicluster/remote_secret_test.go

        users:
        - name: 54643f96-eca0-11e9-bb97-42010a80000a
          user:
            token: token
    ---
    `, clusterNameAnnotationKey, secretName, key)
    
    				if diff := cmp.Diff(got, wantOutput); diff != "" {
    					tt.Errorf("got\n%v\nwant\n%vdiff %v", got, c.want, diff)
    				}
    			}
    		})
    	}
    }
    
    func TestGetServiceAccountSecretToken(t *testing.T) {
    	secret := makeSecret("secret", "caData", "token")
    
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Tue Oct 31 14:48:28 GMT 2023
    - 20.6K bytes
    - Viewed (0)
  5. operator/cmd/mesh/profile-dump_test.go

    				}
    			}
    
    			want, err := readFile(outPath)
    			if err != nil {
    				t.Fatal(err)
    			}
    			if got != want {
    				t.Errorf("profile-dump command(%s): got:\n%s\n\nwant:\n%s\nDiff:\n%s\n", tt.desc, got, want, diff.Diff(got, want))
    			}
    		})
    	}
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Thu Jan 20 11:44:25 GMT 2022
    - 3.7K bytes
    - Viewed (0)
  6. istioctl/pkg/writer/compare/comparator.go

    		return nil, err
    	}
    	c.envoy = envoyDump
    	c.w = w
    	c.context = 7
    	c.location = "Local" // the time.Location for formatting time.Time instances
    	return c, nil
    }
    
    // Diff prints a diff between Istiod and Envoy to the passed writer
    func (c *Comparator) Diff() error {
    	if err := c.ClusterDiff(); err != nil {
    		return err
    	}
    	if err := c.ListenerDiff(); err != nil {
    		return err
    	}
    	return c.RouteDiff()
    }
    
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Sun Apr 21 17:42:54 GMT 2024
    - 3.7K bytes
    - Viewed (1)
  7. operator/cmd/mesh/operator_test.go

    			t.Error(err)
    		}
    	}
    
    	wantYAML, err := readFile(goldenFilepath)
    	if err != nil {
    		t.Fatal(err)
    	}
    
    	if diff := util.YAMLDiff(wantYAML, gotYAML); diff != "" {
    		t.Fatalf("diff: %s", diff)
    	}
    }
    
    func TestOperatorDumpJSONFormat(t *testing.T) {
    	goldenFilepath := filepath.Join(env.IstioSrc, "operator/cmd/mesh/testdata/operator/output/operator-dump.json")
    
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Tue Aug 29 14:15:33 GMT 2023
    - 6.4K bytes
    - Viewed (0)
  8. istioctl/pkg/writer/compare/cluster.go

    		if err != nil {
    			return err
    		}
    		istiodBytes.WriteString(istiod)
    	}
    	diff := difflib.UnifiedDiff{
    		FromFile: "Istiod Clusters",
    		A:        difflib.SplitLines(istiodBytes.String()),
    		ToFile:   "Envoy Clusters",
    		B:        difflib.SplitLines(envoyBytes.String()),
    		Context:  c.context,
    	}
    	text, err := difflib.GetUnifiedDiffString(diff)
    	if err != nil {
    		return err
    	}
    	if text != "" {
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Tue Mar 12 10:02:09 GMT 2024
    - 1.9K bytes
    - Viewed (0)
  9. istioctl/pkg/writer/compare/listener.go

    		if err != nil {
    			return err
    		}
    		istiodBytes.WriteString(istiod)
    	}
    	diff := difflib.UnifiedDiff{
    		FromFile: "Istiod Listeners",
    		A:        difflib.SplitLines(istiodBytes.String()),
    		ToFile:   "Envoy Listeners",
    		B:        difflib.SplitLines(envoyBytes.String()),
    		Context:  c.context,
    	}
    	text, err := difflib.GetUnifiedDiffString(diff)
    	if err != nil {
    		return err
    	}
    	if text != "" {
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Thu Apr 04 20:29:08 GMT 2024
    - 2K bytes
    - Viewed (0)
  10. istioctl/pkg/writer/compare/comparator_test.go

    	comparator, err := NewComparator(&outputBuffer, map[string][]byte{"default": cfg}, cfg)
    	if err != nil {
    		t.Fatalf("Failed to create Comparator: %v", err)
    	}
    	err = comparator.Diff()
    	if err != nil {
    		t.Errorf("Unexpected error during diff: %v", err)
    	}
    
    	expected := []string{"Clusters Match", "Listeners Match", "Routes Match"}
    	for _, exp := range expected {
    		if !bytes.Contains(outputBuffer.Bytes(), []byte(exp)) {
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Tue Mar 12 10:02:09 GMT 2024
    - 2.3K bytes
    - Viewed (0)
Back to top