Spaces:
Paused
Paused
Update Dockerfile
Browse files- Dockerfile +7 -1
Dockerfile
CHANGED
|
@@ -67,6 +67,11 @@ COPY --from=frontend-builder /app/utils/ ./utils/
|
|
| 67 |
COPY --from=frontend-builder /app/frontend/dist/index.html ./templates/
|
| 68 |
COPY --from=frontend-builder /app/frontend/dist/* ./static/
|
| 69 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 70 |
# 创建非 root 用户
|
| 71 |
RUN useradd -m -u 1000 appuser && \
|
| 72 |
chown -R appuser:appuser /app
|
|
@@ -77,4 +82,5 @@ USER appuser
|
|
| 77 |
# 暴露端口 5000
|
| 78 |
EXPOSE 5000
|
| 79 |
|
| 80 |
-
|
|
|
|
|
|
| 67 |
COPY --from=frontend-builder /app/frontend/dist/index.html ./templates/
|
| 68 |
COPY --from=frontend-builder /app/frontend/dist/* ./static/
|
| 69 |
|
| 70 |
+
COPY sync_data.sh /
|
| 71 |
+
COPY entrypoint.sh /entrypoint.sh
|
| 72 |
+
|
| 73 |
+
RUN chmod +x /sync_data.sh /entrypoint.sh
|
| 74 |
+
|
| 75 |
# 创建非 root 用户
|
| 76 |
RUN useradd -m -u 1000 appuser && \
|
| 77 |
chown -R appuser:appuser /app
|
|
|
|
| 82 |
# 暴露端口 5000
|
| 83 |
EXPOSE 5000
|
| 84 |
|
| 85 |
+
# 使用 entrypoint.sh 作为启动命令
|
| 86 |
+
CMD ["/entrypoint.sh"]
|