Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InstanceDryRunDiff ¶
func InstanceDryRunDiff(ctx context.Context, rm *ssa.ResourceManager, objects []*unstructured.Unstructured, staleObjects []*unstructured.Unstructured, nsExists bool, tmpDir string, withDiff bool, w io.Writer) (bool, error)
InstanceDryRunDiff performs a server-side apply dry run of the instance objects and logs the pending change of each one. When withDiff is set, the field changes of the objects that differ from the cluster state are printed to w in YAML diff format, and the dry-run failures are aggregated into the returned error. It returns true if applying the instance would change the cluster state, i.e. if any object would be created, configured or deleted. Mirroring the apply and prune semantics, existing objects annotated as one-off are skipped, and stale objects that are absent from the cluster or annotated with prune disabled are not counted as pending deletions.
Types ¶
type DyffPrinter ¶
type DyffPrinter struct {
OmitHeader bool
}
DyffPrinter is a printer that prints dyff reports.