update README
Browse files
README.md
CHANGED
@@ -12,10 +12,10 @@ curl -X POST http://127.0.0.1:8000/v1/chat/completions \
|
|
12 |
Start the container
|
13 |
|
14 |
```bash
|
15 |
-
docker run -p 8001:8000 --name uni-api -dit \
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
```
|
20 |
|
21 |
Or if you want to use Docker Compose, here is a docker-compose.yml example:
|
@@ -37,6 +37,7 @@ services:
|
|
37 |
Run Docker Compose container in the background
|
38 |
|
39 |
```bash
|
|
|
40 |
docker-compose up -d
|
41 |
```
|
42 |
|
@@ -46,4 +47,17 @@ Docker build
|
|
46 |
docker build --no-cache -t uni-api:latest -f Dockerfile --platform linux/amd64 .
|
47 |
docker tag uni-api:latest yym68686/uni-api:latest
|
48 |
docker push yym68686/uni-api:latest
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
49 |
```
|
|
|
12 |
Start the container
|
13 |
|
14 |
```bash
|
15 |
+
docker run --user root -p 8001:8000 --name uni-api -dit \
|
16 |
+
-v ./api.yaml:/home/api.yaml \
|
17 |
+
-e USE_ROUND_ROBIN=True \
|
18 |
+
yym68686/uni-api:latest
|
19 |
```
|
20 |
|
21 |
Or if you want to use Docker Compose, here is a docker-compose.yml example:
|
|
|
37 |
Run Docker Compose container in the background
|
38 |
|
39 |
```bash
|
40 |
+
docker-compose pull
|
41 |
docker-compose up -d
|
42 |
```
|
43 |
|
|
|
47 |
docker build --no-cache -t uni-api:latest -f Dockerfile --platform linux/amd64 .
|
48 |
docker tag uni-api:latest yym68686/uni-api:latest
|
49 |
docker push yym68686/uni-api:latest
|
50 |
+
```
|
51 |
+
|
52 |
+
One-Click Restart Docker Image
|
53 |
+
|
54 |
+
```bash
|
55 |
+
set -eu
|
56 |
+
docker pull yym68686/uni-api:latest
|
57 |
+
docker rm -f uni-api
|
58 |
+
docker run --user root -p 8001:8000 -dit --name uni-api \
|
59 |
+
-v ./api.yaml:/home/api.yaml \
|
60 |
+
-e USE_ROUND_ROBIN=True \
|
61 |
+
yym68686/uni-api:latest
|
62 |
+
docker logs -f uni-api
|
63 |
```
|