moby/volume/mounts
Sebastiaan van Stijn 49f8a4224c
SELinux: fix ENOTSUP errors not being detected when relabeling
Commit 12c7541f1f updated the
opencontainers/selinux dependency to v1.3.1, which had a breaking
change in the errors that were returned.

Before v1.3.1, the "raw" `syscall.ENOTSUP` was returned if the
underlying filesystem did not support xattrs, but later versions
wrapped the error, which caused our detection to fail.

This patch uses `errors.Is()` to check for the underlying error.
This requires github.com/pkg/errors v0.9.1 or above (older versions
could use `errors.Cause()`, but are not compatible with "native"
wrapping of errors in Go 1.13 and up, and could potentially cause
these errors to not being detected again.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-05-10 17:06:44 +02:00
..
lcow_parser.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
linux_parser.go Entropy cannot be saved 2019-06-07 11:54:45 +01:00
mounts.go SELinux: fix ENOTSUP errors not being detected when relabeling 2020-05-10 17:06:44 +02:00
parser.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
parser_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-11 00:06:42 +01:00
validate.go Tweak bind mount errors 2018-09-28 12:18:58 +02:00
validate_test.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
validate_unix_test.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
validate_windows_test.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
volume_copy.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
volume_unix.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
volume_windows.go Move mount parsing to separate package. 2018-04-19 06:35:54 -04:00
windows_parser.go Entropy cannot be saved 2019-06-07 11:54:45 +01:00