DanielleNguyen commited on
Commit
428a54b
·
verified ·
1 Parent(s): e5681c7

更新下载最新版本

Browse files
Files changed (1) hide show
  1. Dockerfile +24 -22
Dockerfile CHANGED
@@ -1,22 +1,24 @@
1
- FROM debian:bookworm-slim
2
-
3
- WORKDIR /app
4
-
5
- RUN apt-get update && \
6
- apt-get install -y wget ca-certificates && \
7
- rm -rf /var/lib/apt/lists/*
8
-
9
- # Download latest CLI Proxy API
10
- RUN wget -q https://github.com/router-for-me/CLIProxyAPI/releases/download/v6.8.17/CLIProxyAPI_6.8.17_linux_amd64.tar.gz && \
11
- tar -xzf CLIProxyAPI_6.8.17_linux_amd64.tar.gz && \
12
- mv CLIProxyAPI_6.8.17_linux_amd64/cli-proxy-api . && \
13
- rm -rf CLIProxyAPI_6.8.17_linux_amd64* && \
14
- chmod +x cli-proxy-api
15
-
16
- # Copy config and auth files
17
- COPY config.yaml /app/config.yaml
18
- COPY auths /app/auths
19
-
20
- EXPOSE 7860
21
-
22
- CMD ["./cli-proxy-api", "-config", "config.yaml"]
 
 
 
1
+ FROM debian:bookworm-slim
2
+
3
+ WORKDIR /app
4
+
5
+ RUN apt-get update && \
6
+ apt-get install -y wget ca-certificates curl jq && \
7
+ rm -rf /var/lib/apt/lists/*
8
+
9
+ # Download latest CLI Proxy API for Linux
10
+ RUN LATEST_URL=$(curl -s https://api.github.com/repos/router-for-me/CLIProxyAPI/releases/latest | jq -r '.assets[] | select(.name | test("linux.*amd64.*tar.gz")) | .browser_download_url') && \
11
+ echo "Downloading: $LATEST_URL" && \
12
+ wget -q "$LATEST_URL" -O cli-proxy-api.tar.gz && \
13
+ tar -xzf cli-proxy-api.tar.gz && \
14
+ find . -name "cli-proxy-api" -type f -exec mv {} /app/cli-proxy-api \; && \
15
+ rm -rf cli-proxy-api.tar.gz CLIProxyAPI* && \
16
+ chmod +x /app/cli-proxy-api
17
+
18
+ # Copy config and auth files
19
+ COPY config.yaml /app/config.yaml
20
+ COPY auths /app/auths
21
+
22
+ EXPOSE 7860
23
+
24
+ CMD ["./cli-proxy-api", "-config", "config.yaml"]