flzta commited on
Commit
badbcc9
·
verified ·
1 Parent(s): c417808

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -4
Dockerfile CHANGED
@@ -6,7 +6,7 @@ ENV TZ=Asia/Shanghai
6
 
7
  # 下载 Cloudreve 3.8.3
8
  RUN apk update && \
9
- apk add --no-cache wget unzip python3 py3-pip bash tar gzip jq curl && \
10
  rm -rf /var/cache/apk/*
11
 
12
  # 创建 Cloudreve 数据目录
@@ -32,8 +32,11 @@ RUN chmod +x /opt/cloudreve/sync_data.sh
32
  # **确保 /opt/cloudreve 目录及其内容有读写执行权限**
33
  RUN chmod -R 777 /opt/cloudreve/
34
 
35
- # 暴露 Cloudreve 端口
 
 
 
36
  EXPOSE 5212
37
 
38
- # 设置启动命令 to run Cloudreve in foreground and sync script in background
39
- CMD /opt/cloudreve/cloudreve -c /opt/cloudreve/config.ini & /opt/cloudreve/sync_data.sh
 
6
 
7
  # 下载 Cloudreve 3.8.3
8
  RUN apk update && \
9
+ apk add --no-cache wget unzip python3 py3-pip bash tar gzip jq curl aria2 && \
10
  rm -rf /var/cache/apk/*
11
 
12
  # 创建 Cloudreve 数据目录
 
32
  # **确保 /opt/cloudreve 目录及其内容有读写执行权限**
33
  RUN chmod -R 777 /opt/cloudreve/
34
 
35
+ # **新增:创建 Aria2 下载目录并设置权限**
36
+ RUN mkdir -p /opt/cloudreve/aria2_downloads && chmod -R 777 /opt/cloudreve/aria2_downloads
37
+
38
+ # **暴露 Cloudreve 端口**
39
  EXPOSE 5212
40
 
41
+ # 设置启动命令 to run Cloudreve in foreground and sync script in background, and start aria2
42
+ CMD aria2c --enable-rpc --rpc-listen-port=6800 --daemon & /opt/cloudreve/cloudreve -c /opt/cloudreve/config.ini & /opt/cloudreve/sync_data.sh