-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrap error messages during init #1796
Conversation
These look great. Thanks @crosbymichael |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
libcontainer/standard_init_linux.go
Outdated
} | ||
} | ||
for _, path := range l.config.Config.ReadonlyPaths { | ||
if err := readonlyPath(path); err != nil { | ||
return err | ||
return errors.Wrap(err, "set readonly rootfs") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
errors.Wrapf(err, "set readonly path %s", path)
?
libcontainer/standard_init_linux.go
Outdated
} | ||
if l.config.NoNewPrivileges { | ||
if err := unix.Prctl(unix.PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0); err != nil { | ||
return err | ||
return errors.Wrap(err, "set nonewprivilegs") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo: nonewprivilegs -> nonewprivileges
Fixes opencontainers#1437 Signed-off-by: Michael Crosby <[email protected]>
Fixes #1437
Signed-off-by: Michael Crosby [email protected]