Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CFFP-HB
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chao Sun
CFFP-HB
Commits
c11868a0
Commit
c11868a0
authored
Jul 24, 2025
by
zhangxingmin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
push
parent
3d032a88
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
6 deletions
+4
-6
Dockerfile
+4
-6
No files found.
Dockerfile
View file @
c11868a0
...
@@ -14,8 +14,10 @@ RUN npm config set registry https://registry.npmmirror.com \
...
@@ -14,8 +14,10 @@ RUN npm config set registry https://registry.npmmirror.com \
&&
npm config
set
sass_binary_site https://npmmirror.com/mirrors/node-sass/
\
&&
npm config
set
sass_binary_site https://npmmirror.com/mirrors/node-sass/
\
&&
npm cache clean
--force
&&
npm cache clean
--force
# 安装依赖 (移除冗余的清理操作)
# 关键修复:安装特定版本的uni-app相关依赖
RUN
npm install
--legacy-peer-deps
RUN
npm install
-g
@dcloudio/uni-cli-service@latest
\
&&
npm install @dcloudio/vue-cli-plugin-uni@latest
\
&&
npm install
--legacy-peer-deps
# 复制源代码
# 复制源代码
COPY
. .
COPY
. .
...
@@ -25,10 +27,6 @@ RUN npm run build
...
@@ -25,10 +27,6 @@ RUN npm run build
# 生产阶段
# 生产阶段
FROM
nginx:1.21-alpine
FROM
nginx:1.21-alpine
# 替换生产阶段的Alpine源 (可选)
RUN
sed
-i
's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g'
/etc/apk/repositories
COPY
--from=builder /app/dist/build/h5 /usr/share/nginx/html
COPY
--from=builder /app/dist/build/h5 /usr/share/nginx/html
COPY
nginx.conf /etc/nginx/conf.d/default.conf
COPY
nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE
8333
EXPOSE
8333
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment