update
This commit is contained in:
parent
4408899e97
commit
18971cc9eb
@ -13,7 +13,7 @@ COPY package*.json ./
|
||||
# 安装依赖
|
||||
RUN npm install
|
||||
|
||||
# 复制所有源代码
|
||||
# 复制项目文件
|
||||
COPY . .
|
||||
|
||||
# 构建应用
|
||||
@ -22,9 +22,12 @@ RUN npm run build
|
||||
# 生产阶段
|
||||
FROM nginx:stable-alpine as production-stage
|
||||
|
||||
# 从构建阶段复制构建好的文件到nginx目录
|
||||
# 将构建好的文件复制到nginx目录
|
||||
COPY --from=build-stage /app/dist /usr/share/nginx/html
|
||||
|
||||
# 复制nginx配置文件
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
|
||||
# 暴露80端口
|
||||
EXPOSE 80
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user