Description
docker compose events currently only reports container-level events (start, stop, die, etc.). All other event types from the Docker API - such as network, volume, and image events are silently dropped.
The Docker engine already returns these events via the project filter, but Compose discards them before they reach the consumer.
Supporting additional event types would give users better visibility into what's happening across their services - particularly useful for debugging network connectivity issues, volume lifecycle problems, and image pull/build activity.
Possible approach (open to feedback):
- Handle
network, volume, and image event types in addition to container
- Add a
Type field to api.Event so consumers can distinguish event types
- For non-container events, derive the resource identity from
event.Actor.ID and event.Actor.Attributes instead of requiring a service label
- Add unit tests
If core maintainers are in agreement with this feature/enhancement, then I will happily work on this.