Update Dockerfile
Browse files- Dockerfile +2 -2
Dockerfile
CHANGED
|
@@ -35,7 +35,7 @@ RUN chmod -R 777 /opt/cloudreve/
|
|
| 35 |
# **新增:在啟動 Cloudreve 之前刪除 config.ini**
|
| 36 |
RUN rm -f /opt/cloudreve/config.ini
|
| 37 |
|
| 38 |
-
# **新增:创建 Aria2
|
| 39 |
RUN mkdir -p /opt/cloudreve/aria2_downloads && chmod -R 777 /opt/cloudreve/aria2_downloads
|
| 40 |
|
| 41 |
# **新增:复制 Aria2 配置文件 (如果需要)**
|
|
@@ -45,4 +45,4 @@ COPY aria2.conf /etc/aria2/aria2.conf
|
|
| 45 |
EXPOSE 5212
|
| 46 |
|
| 47 |
# 设置启动命令 to run Cloudreve in foreground and sync script in background
|
| 48 |
-
CMD aria2c --conf-path=/etc/aria2/aria2.conf --daemon & /opt/cloudreve/cloudreve -c /opt/cloudreve/config.ini & /opt/cloudreve/sync_data.sh
|
|
|
|
| 35 |
# **新增:在啟動 Cloudreve 之前刪除 config.ini**
|
| 36 |
RUN rm -f /opt/cloudreve/config.ini
|
| 37 |
|
| 38 |
+
# **新增:创建 Aria2 下载目录并设置权限**
|
| 39 |
RUN mkdir -p /opt/cloudreve/aria2_downloads && chmod -R 777 /opt/cloudreve/aria2_downloads
|
| 40 |
|
| 41 |
# **新增:复制 Aria2 配置文件 (如果需要)**
|
|
|
|
| 45 |
EXPOSE 5212
|
| 46 |
|
| 47 |
# 设置启动命令 to run Cloudreve in foreground and sync script in background
|
| 48 |
+
CMD aria2c --conf-path=/etc/aria2/aria2.conf --daemon & sleep 5 && /opt/cloudreve/cloudreve -c /opt/cloudreve/config.ini & /opt/cloudreve/sync_data.sh
|