mirror of
https://github.com/BerriAI/litellm.git
synced 2026-08-28 05:25:59 +00:00
The build_from_pip image ran a bare `prisma generate`, so prisma recorded absolute engine paths under $HOME/.cache, which is /root/.cache in that build. /root is mode 0700 on python:3.13-slim, so any runtime uid other than 0 gets EACCES just traversing it and the proxy dies during prisma client initialisation. That is exactly the shape a securityContext with runAsUser produces. Generate under a fixed /opt/prisma and chmod it a+rX, matching what the shipped images already do, and pin PRISMA_BINARY_CACHE_DIR at runtime so the client resolves the baked engines instead of looking under $HOME. A build-time assertion fails the build if any recorded engine path lands outside the pinned prefix, since the original breakage was silent at build time and only surfaced as a runtime crash for non-root users. |
||
|---|---|---|
| .. | ||
| Dockerfile.build_from_pip | ||
| litellm_config.yaml | ||
| Readme.md | ||
Docker to build LiteLLM Proxy from litellm pip package
When to use this ?
If you need to build LiteLLM Proxy from litellm pip package, you can use this Dockerfile as a reference.
Why build from pip package ?
- If your company has a strict requirement around security / building images you can follow steps outlined here