Skip to content

Commit db55d73

Browse files
author
utam0k
committed
content-service: ignore the error of user.overlay.(impure|origin) attributes
1 parent 1ebf9c3 commit db55d73

File tree

1 file changed

+8
-0
lines changed
  • components/content-service/pkg/archive

1 file changed

+8
-0
lines changed

components/content-service/pkg/archive/tar.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,14 @@ func remapFile(name string, uid, gid int, xattrs map[string]string) error {
198198
if err == syscall.ENOTSUP || err == syscall.EPERM {
199199
continue
200200
}
201+
if strings.HasPrefix(key, "user.") {
202+
// This is a marker to match inodes, such as when an upper layer copies a lower layer file in overlayfs.
203+
// However, when restoring a content, the container in the workspace is not always running, so there is no problem ignoring the failure.
204+
if strings.HasSuffix(key, ".overlay.impure") || strings.HasSuffix(key, ".overlay.origin") {
205+
continue
206+
}
207+
}
208+
201209
log.WithField("name", key).WithField("value", value).WithField("file", name).WithError(err).Warn("restoring extended attributes")
202210
}
203211
}

0 commit comments

Comments
 (0)