Update Dockerfile
Browse files- Dockerfile +4 -1
Dockerfile
CHANGED
|
@@ -6,4 +6,7 @@ RUN apt-get update && apt-get install -y ca-certificates && rm -rf /var/lib/apt/
|
|
| 6 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 7 |
COPY . .
|
| 8 |
EXPOSE 7860
|
| 9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 7 |
COPY . .
|
| 8 |
EXPOSE 7860
|
| 9 |
+
# ... 前面保持不变 ...
|
| 10 |
+
|
| 11 |
+
# 修改启动命令,启动前先尝试刷新一下 DNS 缓存(虽然权限有限,但能触发系统重新拉取解析)
|
| 12 |
+
CMD python -c "import socket; print(socket.gethostbyname('discord.com'))" && python app.py
|