update
This commit is contained in:
parent
214b3782c7
commit
a3d80b1023
10
Dockerfile
10
Dockerfile
@ -23,12 +23,10 @@ RUN npm run build
|
|||||||
# 生产阶段
|
# 生产阶段
|
||||||
FROM nginx:stable-alpine as production-stage
|
FROM nginx:stable-alpine as production-stage
|
||||||
|
|
||||||
# 复制构建产物到 Nginx 目录
|
# 将构建好的文件复制到 nginx 目录
|
||||||
COPY --from=build-stage /app/dist /usr/share/nginx/html
|
COPY --from=build-stage /app/dist /usr/share/nginx/html/
|
||||||
|
# 将 static 目录下的文件直接复制到网站根目录
|
||||||
# 复制 static 目录下的文件到 Nginx 根目录
|
COPY --from=build-stage /app/src/static /usr/share/nginx/html/
|
||||||
COPY static/ /usr/share/nginx/html/
|
|
||||||
|
|
||||||
|
|
||||||
# 暴露 80 端口
|
# 暴露 80 端口
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user