LinuxCommandLibrary

kubectl-diff

shows differences between the current live configuration and the proposed

TLDR

Show diff against live configuration

$ kubectl diff -f [manifest.yaml]
copy
Diff entire directory
$ kubectl diff -f [manifests/]
copy
Diff from stdin
$ cat [manifest.yaml] | kubectl diff -f -
copy

SYNOPSIS

kubectl diff [options]

DESCRIPTION

kubectl diff shows differences between the current live configuration and the proposed configuration in a file. Useful for previewing changes before applying them. Uses server-side dry run to compute the diff.

PARAMETERS

-f, --filename file

File containing configuration to diff.
-R, --recursive
Process directory recursively.
-l, --selector selector
Label selector for filtering.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community