63a218a458
Need to mv to latest released and supported version of logrus switch github.com/Sirupsen/logrus github.com/sirupsen/logrus Also vendor in latest containers/storage and containers/image Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
21 lines
396 B
Go
21 lines
396 B
Go
// +build linux
|
|
|
|
package aufs
|
|
|
|
import (
|
|
"os/exec"
|
|
"syscall"
|
|
|
|
"github.com/sirupsen/logrus"
|
|
)
|
|
|
|
// Unmount the target specified.
|
|
func Unmount(target string) error {
|
|
if err := exec.Command("auplink", target, "flush").Run(); err != nil {
|
|
logrus.Warnf("Couldn't run auplink before unmount %s: %s", target, err)
|
|
}
|
|
if err := syscall.Unmount(target, 0); err != nil {
|
|
return err
|
|
}
|
|
return nil
|
|
}
|