diff --git a/content/en/docs/reference/labels-annotations-taints/_index.md b/content/en/docs/reference/labels-annotations-taints/_index.md index f5be1a7d65..1c5bf8326c 100644 --- a/content/en/docs/reference/labels-annotations-taints/_index.md +++ b/content/en/docs/reference/labels-annotations-taints/_index.md @@ -1275,6 +1275,25 @@ The kubectl command line tool uses this annotation as a legacy mechanism to track changes. That mechanism has been superseded by [Server-side apply](/docs/reference/using-api/server-side-apply/). +### kubectl.kubernetes.io/restartedAt {#kubectl-k8s-io-restart-at} + +Type: Annotation + +Example: `kubectl.kubernetes.io/restartedAt: "2024-06-21T17:27:41Z"` + +Used on: Deployment, ReplicaSet, StatefulSet, DaemonSet, Pod + +This annotation contains the latest restart time of a resource (Deployment, ReplicaSet, StatefulSet or DaemonSet), +where kubectl triggered a rollout in order to force creation of new Pods. +The command `kubectl rollout restart ` triggers a restart by patching the template +metadata of all the pods of resource with this annotation. In above example the latest restart time is shown as 21st June 2024 at 17:27:41 UTC. + +You should not assume that this annotation represents the date / time of the most recent update; +a separate change could have been made since the last manually triggered rollout. + +If you manually set this annotation on a Pod, nothing happens. The restarting side effect comes from +how workload management and Pod templating works. + ### endpoints.kubernetes.io/over-capacity Type: Annotation