mount

package
v0.3.8-dev-trailers Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 1, 2015 License: MIT Imports: 9 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

package mount provides a simple abstraction around a mount point

Index

Constants

This section is empty.

Variables

View Source
var MountTimeout = time.Second * 5

Functions

func Closer added in v0.3.6

func Closer(m Mount) io.Closer

func ForceUnmount

func ForceUnmount(m Mount) error

ForceUnmount attempts to forcibly unmount a given mount. It does so by calling diskutil or fusermount directly.

func ForceUnmountManyTimes

func ForceUnmountManyTimes(m Mount, attempts int) error

ForceUnmountManyTimes attempts to forcibly unmount a given mount, many times. It does so by calling diskutil or fusermount directly. Attempts a given number of times.

Types

type Mount

type Mount interface {
	// MountPoint is the path at which this mount is mounted
	MountPoint() string

	// Unmounts the mount
	Unmount() error

	// Process returns the mount's Process to be able to link it
	// to other processes. Unmount upon closing.
	Process() goprocess.Process
}

Mount represents a filesystem mount

func NewMount

func NewMount(p goprocess.Process, fsys fs.FS, mountpoint string, allow_other bool) (Mount, error)

Mount mounts a fuse fs.FS at a given location, and returns a Mount instance. parent is a ContextGroup to bind the mount's ContextGroup to.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL