Skip to content

hooks: retained pre_start containers removed before service containers on compose down -v #14109

Description

@glours

This issue was filed by an AI agent on a human's behalf. The human submitter may not have independently verified the report.

removePreStartHookContainers is called before service containers are stopped in down() (PR #14091, down.go:110). Hook containers share volumes with the service container via VolumesFrom. Removing them with -v before stopping the service container may cause volume leaks if the service container holds anonymous volume references.

Suggested fix: move the hook-container sweep to after service container removal, or at minimum verify the ordering is safe.

Mentioned in #14091 review by @ndeloof (down.go:110).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions