Skip to content
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

unpack: cleanup bundle in case of failure #187

Merged
merged 1 commit into from
Oct 6, 2017

Conversation

cyphar
Copy link
Member

@cyphar cyphar commented Oct 5, 2017

In order to ensure we don't leave around a broken bundle directory,
remove the bundle if a failure occurred. While cleaning up isn't a huge
issue for unpacking as root, cleaning up as an unprivileged user gets
quite complicated ("rm -rf" doesn't work).

Fixes #174
Reported-by: "Serge E. Hallyn" serge@hallyn.com
Signed-off-by: Aleksa Sarai asarai@suse.de

/cc @hallyn

In order to ensure we don't leave around a broken bundle directory,
remove the bundle if a failure occurred. While cleaning up isn't a huge
issue for unpacking as root, cleaning up as an unprivileged user gets
quite complicated ("rm -rf" doesn't work).

Reported-by: "Serge E. Hallyn" <serge@hallyn.com>
Signed-off-by: Aleksa Sarai <asarai@suse.de>
@cyphar
Copy link
Member Author

cyphar commented Oct 6, 2017

LGTM.

@cyphar cyphar merged commit c697175 into opencontainers:master Oct 6, 2017
cyphar added a commit that referenced this pull request Oct 6, 2017
  unpack: cleanup bundle in case of failure

LGTMs: @cyphar
Closes #187
@cyphar cyphar deleted the unpack-cleanup-rootfs branch October 6, 2017 02:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant