Skip to content

fix(stop,clean): scope cleanup to foc-devnet images, not the foc- prefix#111

Merged
rvagg merged 3 commits intomainfrom
rvagg/careful-cleanup
May 7, 2026
Merged

fix(stop,clean): scope cleanup to foc-devnet images, not the foc- prefix#111
rvagg merged 3 commits intomainfrom
rvagg/careful-cleanup

Conversation

@rvagg
Copy link
Copy Markdown
Contributor

@rvagg rvagg commented May 7, 2026

I run other foc-* containers on my machine so this is a problem ...

Copilot AI review requested due to automatic review settings May 7, 2026 09:11
@FilOzzy FilOzzy added this to FOC May 7, 2026
@github-project-automation github-project-automation Bot moved this to 📌 Triage in FOC May 7, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR tightens stop/clean Docker cleanup so it targets foc-devnet-owned resources (by image identity) rather than sweeping up anything that happens to share the foc- prefix, addressing conflicts with other foc-* containers on a developer machine.

Changes:

  • Added an is_foc_devnet_image(...) helper to identify foc-devnet images (optionally tagged).
  • Replaced prefix-based container discovery with image-based discovery for log persistence and dead-container removal.
  • Updated stop and clean to use the new foc-devnet container/image identification logic.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/docker/mod.rs Re-exports the renamed container listing helper used by stop/log cleanup.
src/docker/logs.rs Switches container selection from image-prefix matching to foc-devnet image identification.
src/constants.rs Adds is_foc_devnet_image(...) to centralize foc-devnet image identification.
src/commands/stop.rs Updates force-kill logic to target containers by foc-devnet images instead of name prefix; adjusts network cleanup filter.
src/commands/clean.rs Updates image removal to target only foc-devnet images rather than foc-* prefix.

Comment thread src/commands/stop.rs Outdated
Comment thread src/docker/logs.rs Outdated
@rvagg rvagg force-pushed the rvagg/careful-cleanup branch from 14afdbd to 4ba8124 Compare May 7, 2026 13:30
@rvagg rvagg merged commit f0ae175 into main May 7, 2026
5 of 6 checks passed
@rvagg rvagg deleted the rvagg/careful-cleanup branch May 7, 2026 14:30
@github-project-automation github-project-automation Bot moved this from 📌 Triage to 🎉 Done in FOC May 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 🎉 Done

Development

Successfully merging this pull request may close these issues.

3 participants