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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix live-restore w/ restart policies + volume refs #44231
Conversation
Before this change restarting the daemon in live-restore with running containers + a restart policy meant that volume refs were not restored. This specifically happens when the container is still running *and* there is a restart policy that would make sure the container was running again on restart. The bug allows volumes to be removed even though containers are referencing them. 馃槺 Signed-off-by: Brian Goff <cpuguy83@gmail.com>
t.Run("volume references", testLiveRestoreVolumeReferences) | ||
} | ||
|
||
func testLiveRestoreVolumeReferences(t *testing.T) { |
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.
Was there a specific reason for splitting this into two functions? (I can see the reason for the subtests inside testLiveRestoreVolumeReferences()
, but was a bit confused about the split here 馃槄 馃
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.
Potential other live restore tests.
Just namespacing.
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, thanks!
I was wondering indeed when reading that ticket some time ago, but hadn't found the time to dig in "what step" we were missing; thanks!
@cpuguy83 Wonderful work, thank you! |
Before this change restarting the daemon in live-restore with running containers + a restart policy meant that volume refs were not restored. This specifically happens when the container is still running and there is a restart policy that would make sure the container was running again on restart.
The bug allows volumes to be removed even though containers are referencing them. 馃槺
Fixes #41686