diff --git a/.env.example b/.env.example index c87c2ef8fd..82b09ca25e 100644 --- a/.env.example +++ b/.env.example @@ -20,3 +20,8 @@ REPLICATE_API_TOKEN = "" ANTHROPIC_API_KEY = "" # Infisical INFISICAL_TOKEN = "" + +# Development Configs +LITELLM_MASTER_KEY = "sk-1234" +DATABASE_URL = "postgresql://llmproxy:dbpassword9090@db:5432/litellm" +STORE_MODEL_IN_DB = "True" \ No newline at end of file diff --git a/README.md b/README.md index 12b8bfa9dd..7260e50bc8 100644 --- a/README.md +++ b/README.md @@ -451,3 +451,20 @@ If you have suggestions on how to improve the code quality feel free to open an + + +## Run in Developer mode +### Services +1. Setup .env file in root +2. Run dependant services `docker-compose up db prometheus` + +### Backend +1. (In root) create virtual environment `python -m venv .venv` +2. Activate virtual environment `source .venv/bin/activate` +3. Install dependencies `pip install -e ".[all]"` +4. Start proxy backend `uvicorn litellm.proxy.proxy_server:app --host localhost --port 4000 --reload` + +### Frontend +1. Navigate to `ui/litellm-dashboard` +2. Install dependencies `npm install` +3. Run `npm run dev` to start the dashboard \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 1508bd375c..78044c03b8 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -29,6 +29,8 @@ services: POSTGRES_DB: litellm POSTGRES_USER: llmproxy POSTGRES_PASSWORD: dbpassword9090 + ports: + - "5432:5432" healthcheck: test: ["CMD-SHELL", "pg_isready -d litellm -U llmproxy"] interval: 1s