Skip to content

chore: clean uv pip cache after MCP venv install in Dockerfile.base #27

@kordless

Description

@kordless

Problem

From the image bloat analysis: after uv pip install populates /opt/mcp-venv, the uv download cache at /root/.cache/uv is left in the layer. This is unnecessary in a runtime image.

Fix

Add to the Python venv RUN block in Dockerfile.base:

```dockerfile
&& rm -rf /root/.cache/uv
```

Expected savings

Varies by package count, typically 100-300 MB depending on the wheel cache size.

Context

Part of the ongoing image bloat reduction work (see also #17, #18).

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