GoogleCloudPlatform/kubernetes — pull request #688 by Sarsate (2014-07-29 21:42:05+00:00)
Title: Volume reconciliation loop

Implements a reconciliation loop that tears down volumes that are no longer in use by any pod.

The set of valid volumes are determined by iterating through the list of manifests. The set of active, or mounted, volumes are determined by traversing the root working directory path for any existing volumes. These maps are compared, and if an active volume does not have a match, it is unmounted and removed.

This allows a kubelet to properly remove mounted volumes and clean up after itself in the event of a crash/restart.