Skip to content

Commit 3ed64be

Browse files
committed
Update README.md
1 parent 70dd702 commit 3ed64be

1 file changed

Lines changed: 14 additions & 52 deletions

File tree

README.md

Lines changed: 14 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ pip install llms-py
7373

7474
### Using Docker
7575

76-
Run llms-py in a Docker container without installing Python or dependencies:
76+
a) Simple - Run in a Docker container:
7777

7878
```bash
7979
# Pull the latest image from GitHub Container Registry
@@ -83,76 +83,38 @@ docker pull ghcr.io/servicestack/llms:latest
8383
docker run -p 8000:8000 -e GROQ_API_KEY=$GROQ_API_KEY ghcr.io/servicestack/llms:latest
8484
```
8585

86-
Or use docker-compose (recommended):
86+
Use custom `llms.json` and `ui.json` config files outside of the container (auto created if not exists):
8787

8888
```bash
89-
docker-compose up
89+
docker run -p 8000:8000 -e GROQ_API_KEY=$GROQ_API_KEY \
90+
-v ~/.llms:/home/llms/.llms \
91+
ghcr.io/servicestack/llms:latest
9092
```
9193

92-
**Using docker-compose** (recommended for local development):
94+
b) Recommended - Use Docker Compose
9395

94-
1. Create a `.env` file with your API keys:
96+
Download and use [docker-compose.yml](https://raw.githubusercontent.com/ServiceStack/llms/refs/heads/main/docker-compose.yml):
9597

9698
```bash
97-
OPENROUTER_API_KEY=your-key
98-
GROQ_API_KEY=your-key
99-
GOOGLE_FREE_API_KEY=your-key
100-
# Add other API keys as needed
99+
curl -O https://raw.githubusercontent.com/ServiceStack/llms/refs/heads/main/docker-compose.yml
101100
```
102101

103-
2. Start the server:
102+
Update API Keys in `docker-compose.yml` then start the server:
103+
104104
```bash
105105
docker-compose up -d
106106
```
107107

108-
3. Access the UI at `http://localhost:8000`
109-
110-
**Building locally:**
108+
c) Build and run local Docker image from source:
111109

112110
```bash
113-
# Build the Docker image
114-
./docker-build.sh
111+
git clone https://github.com/ServiceStack/llms
115112

116-
# Or manually
117-
docker build -t llms-py:latest .
118-
119-
# Run the container
120-
docker run -p 8000:8000 \
121-
-e OPENROUTER_API_KEY="your-key" \
122-
llms-py:latest
113+
docker-compose -f docker-compose.local.yml up -d --build
123114
```
124115

125-
**Persisting configuration:**
126-
127-
To persist your llms configuration between container restarts, mount a volume:
116+
After the container starts, you can access the UI at `http://localhost:8000`.
128117

129-
```bash
130-
docker run -p 8000:8000 \
131-
-v llms-data:/home/llms/.llms \
132-
-e OPENROUTER_API_KEY="your-key" \
133-
ghcr.io/servicestack/llms:latest
134-
```
135-
136-
The `docker-compose.yml` file automatically creates a named volume for persistence.
137-
138-
**Using custom configuration files:**
139-
140-
You can provide your own `llms.json` and `ui.json` configuration files:
141-
142-
```bash
143-
# Mount a local directory with your custom configs
144-
docker run -p 8000:8000 \
145-
-v $(pwd)/config:/home/llms/.llms \
146-
-e OPENROUTER_API_KEY="your-key" \
147-
ghcr.io/servicestack/llms:latest
148-
149-
# Or mount individual config files
150-
docker run -p 8000:8000 \
151-
-v $(pwd)/my-llms.json:/home/llms/.llms/llms.json:ro \
152-
-v $(pwd)/my-ui.json:/home/llms/.llms/ui.json:ro \
153-
-e OPENROUTER_API_KEY="your-key" \
154-
ghcr.io/servicestack/llms:latest
155-
```
156118

157119
See [DOCKER.md](DOCKER.md) for detailed instructions on customizing configuration files.
158120

0 commit comments

Comments
 (0)