Spaces:
Running
Running
Update Dockerfile
Browse files- Dockerfile +4 -2
Dockerfile
CHANGED
@@ -17,7 +17,9 @@ RUN python3 -m venv $VIRTUAL_ENV
|
|
17 |
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
|
18 |
RUN pip install --no-cache-dir requests webdavclient3 huggingface_hub
|
19 |
|
20 |
-
|
|
|
|
|
21 |
tar -xzf openlist-linux-amd64.tar.gz && \
|
22 |
find . -type f -name "openlist" -exec chmod +x {} \; && \
|
23 |
find . -type f -name "openlist" -exec mv {} . \; && \
|
@@ -29,4 +31,4 @@ RUN chmod +x $HOME/app/sync_data.sh
|
|
29 |
RUN chown -R user:user /home/user
|
30 |
|
31 |
USER user
|
32 |
-
CMD ["/bin/bash", "-c", "$HOME/app/sync_data.sh & sleep 15 && ./openlist server"]
|
|
|
17 |
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
|
18 |
RUN pip install --no-cache-dir requests webdavclient3 huggingface_hub
|
19 |
|
20 |
+
# 获取最新版本的 OpenList 并下载
|
21 |
+
RUN LATEST_VERSION=$(curl -s https://api.github.com/repos/OpenListTeam/OpenList/releases/latest | jq -r .tag_name) && \
|
22 |
+
wget -q https://github.com/OpenListTeam/OpenList/releases/download/${LATEST_VERSION}/openlist-linux-amd64.tar.gz && \
|
23 |
tar -xzf openlist-linux-amd64.tar.gz && \
|
24 |
find . -type f -name "openlist" -exec chmod +x {} \; && \
|
25 |
find . -type f -name "openlist" -exec mv {} . \; && \
|
|
|
31 |
RUN chown -R user:user /home/user
|
32 |
|
33 |
USER user
|
34 |
+
CMD ["/bin/bash", "-c", "$HOME/app/sync_data.sh & sleep 15 && ./openlist server"]
|