# Functions
CleanupContent removes every temporary mountpoint created under ${containerDir}/overlay as a result of however many calls to TempDir(), roughly equivalent to calling RemoveTemp() for each of the directories whose paths it returned, and then removes ${containerDir} itself.
CleanupMount removes all temporary mountpoint content.
GenerateStructure generates an overlay directory structure for container content.
Mount creates a subdir of the contentDir based on the source directory from the source system.
MountReadOnly creates a subdir of the contentDir based on the source directory from the source system.
MountWithOptions creates ${contentDir}/merge, where ${contentDir} was presumably created and returned by a call to TempDir(), and either mounts a filesystem there and returns a mounts.Spec which bind-mounts the mountpoint to ${dest}, or returns a mounts.Spec which mounts a filesystem at ${dest}.
RemoveTemp unmounts a filesystem mounted at ${contentDir}/merge, and then removes ${contentDir}, which is typically a path returned by TempDir(), along with any contents it might still have.
TempDir generates a uniquely-named directory under ${containerDir}/overlay which can be used as a parent directory for the upper and working directories for an overlay mount, creates "upper" and "work" directories beneath it, and then returns the path of the new directory.
Unmount the overlay mountpoint at ${contentDir}/merge, where ${contentDir} is typically a path returned by TempDir().