1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00
moby--moby/container
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
..
stream remove uses of deprecated pkg/term 2020-04-21 16:29:27 +02:00
archive.go container.BaseFS: check for nil before deref 2018-03-13 21:24:48 -07:00
container.go Support configuration of log cacher. 2020-02-19 17:02:34 -05:00
container_unit_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-11 00:06:42 +01:00
container_unix.go SELinux: fix ENOTSUP errors not being detected when relabeling 2020-05-10 17:06:44 +02:00
container_windows.go container.ConfigFilePath: use same signature on Windows 2019-09-03 10:51:43 +02:00
env.go Add canonical import comment 2018-02-05 16:51:57 -05:00
env_test.go Add canonical import comment 2018-02-05 16:51:57 -05:00
health.go Avoid a data race in container/health.go 2019-07-31 13:17:32 -07:00
history.go Add canonical import comment 2018-02-05 16:51:57 -05:00
memory_store.go Add canonical import comment 2018-02-05 16:51:57 -05:00
memory_store_test.go Add canonical import comment 2018-02-05 16:51:57 -05:00
monitor.go Make sure timers are stopped after use. 2019-01-16 14:32:53 -08:00
mounts_unix.go mount: add BindOptions.NonRecursive (API v1.40) 2018-11-06 17:51:58 +09:00
mounts_windows.go Add canonical import comment 2018-02-05 16:51:57 -05:00
state.go goimports: fix imports 2019-09-18 12:56:54 +02:00
state_test.go cleanup: remove SetDead function 2019-08-25 20:34:30 +08:00
store.go Add canonical import comment 2018-02-05 16:51:57 -05:00
view.go goimports: fix imports 2019-09-18 12:56:54 +02:00
view_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-11 00:06:42 +01:00