1 Star 0 Fork 617

curko/PlayEdu开源培训系统

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Dockerfile 1.51 KB
一键复制 编辑 原始数据 按行查看 历史
白书科技 提交于 2024-07-05 05:36 . !10 compose镜像加速
FROM registry.cn-hangzhou.aliyuncs.com/hzbs/node:20-alpine AS node-builder
COPY playedu-admin /app/admin
COPY playedu-pc /app/pc
COPY playedu-h5 /app/h5
WORKDIR /app/admin
RUN pnpm i && VITE_APP_URL=/api/ pnpm build
WORKDIR /app/pc
RUN pnpm i && VITE_APP_URL=/api/ pnpm build
WORKDIR /app/h5
RUN pnpm i && VITE_APP_URL=/api/ pnpm build
FROM registry.cn-hangzhou.aliyuncs.com/hzbs/eclipse-temurin:17 AS java-builder
COPY playedu-api /app
WORKDIR /app
RUN /app/mvnw -Dmaven.test.skip=true clean package
FROM registry.cn-hangzhou.aliyuncs.com/hzbs/eclipse-temurin:17 AS base
COPY --from=java-builder /app/playedu-api/target/playedu-api.jar /app/api/app.jar
COPY --from=node-builder /app/admin/dist /app/admin
COPY --from=node-builder /app/pc/dist /app/pc
COPY --from=node-builder /app/h5/dist /app/h5
COPY docker/nginx/conf/nginx.conf /etc/nginx/sites-enabled/default
CMD nginx; echo "Waiting for MySQL/Redis/MinIO to start..."; sleep 15; java -jar /app/api/app.jar --spring.profiles.active=prod --spring.datasource.url="jdbc:mysql://${DB_HOST}:${DB_PORT:-3306}/${DB_NAME}?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false&allowPublicKeyRetrieval=true" --spring.datasource.username=${DB_USER} --spring.datasource.password=${DB_PASS} --spring.data.redis.host=${REDIS_HOST} --spring.data.redis.port=${REDIS_PORT:-6379} --spring.data.redis.password=${REDIS_PASS} --spring.data.redis.database=${REDIS_DB:-0} --sa-token.is-concurrent=${SA_TOKEN_IS_CONCURRENT:-false} --sa-token.jwt-secret-key=${SA_TOKEN_JWT_SECRET_KEY}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/curko/playedu.git
[email protected]:curko/playedu.git
curko
playedu
PlayEdu开源培训系统
main

搜索帮助