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

Make sure all containers get cleaned up on stop and poweroff, fixes #4676 #4680

Merged
merged 6 commits into from
Mar 1, 2023

Conversation

rfay
Copy link
Member

@rfay rfay commented Feb 26, 2023

The Issue

Manual Testing Instructions

  • Use debugger to make sure Chowning volume contents can result in dead containers that don't get removed #4676 doesn't happen any more
  • Try ddev config with images not downloaded, verify that download time is slight.
  • Create containers like a failure would; docker run --label "com.ddev.site-name:xxx" busybox true and then ddev stop (where name matches) or ddev poweroff (where name doesn't match project)
  • Verify that unlabeled containers do not get deleted by these things.

Automated Testing Overview

No new tests are added

Related Issue Link(s)

Release/Deployment Notes

@github-actions
Copy link

@rfay rfay changed the title Make sure all containers get cleaned up on stop and poweroff Make sure all containers get cleaned up on stop and poweroff, fixes #4676 Feb 26, 2023
@rfay
Copy link
Member Author

rfay commented Feb 27, 2023

@miromichalicka I'd love to have you review and test this.

Assets for testing are in #4680 (comment)

@miromichalicka
Copy link
Contributor

Cool, I'll try to test it tonight.

@rfay
Copy link
Member Author

rfay commented Mar 1, 2023

Manual testing:

  • ddev config with brand-new docker works much better, just pulls busybox.
  • Images pulled early in app.Start() correctly.
  • Created a running project with docker run -it --label=com.ddev.site-name=junk busybox and then did ddev stop and the extra container was stopped.
  • Created an unattached container with docker run -it --label=com.ddev.site-name=xxx busybox and did ddev poweroff and it was deleted.
  • Unattached containers without the com.ddev.site-name label were not deleted.

I think it's all good.

@rfay rfay merged commit 0cb1f20 into ddev:master Mar 1, 2023
@rfay rfay deleted the 20230226_run_simple_container branch March 1, 2023 23:52
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.

2 participants