-
Notifications
You must be signed in to change notification settings - Fork 128
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
Enable resuming snapshot for jailed firecracker #544
Enable resuming snapshot for jailed firecracker #544
Conversation
f5d23c9
to
f301638
Compare
4d7df63
to
6083026
Compare
6083026
to
7699d06
Compare
Signed-off-by: Albin Vass <[email protected]>
Signed-off-by: Albin Vass <[email protected]>
7699d06
to
7d76793
Compare
@@ -426,6 +426,24 @@ func LinkFilesHandler(kernelImageFileName string) Handler { | |||
m.Cfg.Drives[i].PathOnHost = String(driveFileName) | |||
} | |||
|
|||
if m.Cfg.hasSnapshot() { |
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.
hasSnapshot
returns true if either snapshotPath or memFilePath is non-empty, so we should check if the individual file paths are non-empty, before creating the file link.
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.
Thanks for the PR. Can you please add/update unit test for this change in jailer_test.go
.
This is necessary to support the usage of devmapper or other devices for drives.
c827813
to
d323c9a
Compare
670922e
to
288c809
Compare
Issue #, if available:
Description of changes:
This links the memory and snapshot files into the root of the jail and fixes an issue where
WithSnapshots
overrides the injectedLinkFilesHandler
.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.