|
|
4 weeks ago | |
|---|---|---|
| .. | ||
| config/examples | 4 weeks ago | |
| other | 4 weeks ago | |
| Makefile | 4 weeks ago | |
| README.md | 4 weeks ago | |
| litellm.container | 4 weeks ago | |
| litellm.image | 4 weeks ago | |
| litellm.target | 4 weeks ago | |
| overlay.bu | 4 weeks ago | |
README.md
Podman Quadlet: LiteLLM
Overview
LiteLLM is an LLM gateway (proxy server) that exposes 100+ LLM providers behind a single, OpenAI-compatible API, with authentication, budgets, rate limiting and a management UI.
This cookbook:
- Runs LiteLLM in proxy mode using the non-root container image
(
ghcr.io/berriai/litellm-non_root), which runs as UID/GID65534. UID/GID mapping remaps it to the dedicatedlitellmuser (10024) and theitix-svcgroup (10000) on the host. - Reads its behaviour from a configuration file (
config.yaml). - Reads secrets and passwords (master key, UI credentials, database URL) from a
separate
config.envfile injected as environment variables. - Redirects the root path (
/) to the Admin UI (/ui) and serves the API docs under/docs. - Uses PostgreSQL as its backend (requires the
postgresqlcookbook) to persist keys, models and spend logs. - Is published through Traefik (requires the
traefikcookbook).
Prerequisites
- The
postgresqlcookbook must be installed and running. - The
traefikcookbook must be installed and running. - Configuration files
/etc/quadlets/litellm/config.yamland/etc/quadlets/litellm/config.envmust exist (copied from the examples).
Configuration
-
config.yaml— proxy configuration (model_list,general_settings, ...). See https://docs.litellm.ai/docs/proxy/config_settings. -
config.env— secrets injected as environment variables:Variable Purpose LITELLM_MASTER_KEYMaster key for the proxy (must start with sk-)UI_USERNAMEUsername to sign in on the Admin UI UI_PASSWORDPassword to sign in on the Admin UI DATABASE_URLPostgreSQL connection string The root redirect (
ROOT_REDIRECT_URL=/ui) and docs path (DOCS_URL=/docs) are set directly in the Quadlet file.
Ports
- TCP
4000: LiteLLM proxy / Admin UI (bound on127.0.0.1, exposed through Traefik).
UID / GID
- User
litellm: UID10024 - Group
itix-svc: GID10000 - Inside the container the process runs as
65534:65534(mapped to the host IDs above).
Usage
In a separate terminal, follow the logs.
sudo make tail-logs
Install the Podman Quadlets and start LiteLLM.
sudo make clean install
You should see the litellm.service waiting for PostgreSQL to be available, then running its database migrations and starting up.
Verify LiteLLM is running using its liveness endpoint:
curl -sSf http://127.0.0.1:4000/health/liveliness
Then browse to the service through Traefik (the root path redirects to /ui):
curl --resolve litellm:80:127.0.0.1 -L http://litellm/
Finally, remove the quadlets, their configuration and their data.
sudo make uninstall clean