github.com/cvmfs/docker-graphdriver@v0.0.0-20181206110523-155ec6df0521/plugins/aufs_cvmfs/aufs/commit.go (about) 1 package aufs 2 3 import ( 4 "errors" 5 "path" 6 7 "github.com/cvmfs/docker-graphdriver/plugins/util" 8 ) 9 10 func (a *Driver) getParentThinLayer(id string) (util.ThinImage, error) { 11 roLayers, _ := getParentIDs(a.rootPath(), id) 12 var thin util.ThinImage 13 14 for _, l := range roLayers { 15 diffPath := a.getDiffPath(l) 16 if util.IsThinImageLayer(diffPath) { 17 return util.ReadThinFile(path.Join(diffPath, "thin.json")), nil 18 } 19 } 20 21 return thin, errors.New("Not a thin image!") 22 }