maple.utils.cleanup.CleanupManager.register_handler
- CleanupManager.register_handler(name: str, handler: Callable) None
Register a custom cleanup handler function.
Custom handlers are called during cleanup_all() after containers are stopped. Useful for cleaning up non-Docker resources like temporary files, locks, or connections.
- Parameters:
name – Unique identifier for the cleanup handler.
handler – Callable that performs cleanup (takes no arguments).