Commit Graph

5 Commits

Author SHA1 Message Date
f2161c68da feat: add WeChat environment variables to docker-compose
## Changes

### Docker Compose Configuration
- Add WECHAT_APP_ID environment variable to server service
- Add WECHAT_APP_SECRET environment variable to server service
- Add WECHAT_REDIRECT_URI environment variable to server service

## Purpose
Enable WeChat Open Platform QR code login functionality by passing
WeChat credentials from .env file to the server container.

## Testing
- All containers started successfully
- Server loaded configuration correctly
- WeChat login endpoints are now available

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-03 14:48:04 +08:00
296f6e09f8 fix: add MySQL database and fix deployment issues
## Changes

### Database Integration
- Add MySQL 8.0 service to docker-compose.yml
- Configure DATABASE_URL environment variable for server
- Add health check for MySQL service
- Create mysql_data volume for data persistence

### Dockerfile Improvements
- Generate Prisma Client in builder stage
- Copy Prisma Client from correct pnpm workspace location
- Ensure Prisma Client is available in production container

### Client-Mobile Fixes
- Remove deprecated StampDock.vue component
- Fix voting store API usage in VotingPage.vue
- Add type assertion for userTickets in connection.ts
- Add remark property to AwardConfig interface in voting.ts

## Testing
- All containers start successfully
- Database connection established
- Redis connection working
- 94 participants restored from Redis
- Vote data synced (20 votes)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-02 21:46:51 +08:00
371f117064 fix: production deployment improvements and configuration fixes
## 主要改动

### 1. 修复二维码地址硬编码问题
- 将 MainDisplay.vue 中硬编码的移动端 URL 改为环境变量配置
- 添加 VITE_MOBILE_URL 环境变量支持
- 支持通过 .env 文件动态配置移动端地址

### 2. 修复音频文件路径问题
- 修正 display.ts 中音频文件路径,添加 /screen 前缀
- 修复 BGM、抽奖音效、胜利音效的加载路径

### 3. 修复 Docker 构建问题
- 添加中国 npm 镜像配置,解决构建超时问题
- 修复缺失的 tsconfig.base.json 文件拷贝
- 修复 Redis 环境变量配置(REDIS_HOST/REDIS_PORT)
- 添加 Lua 脚本文件拷贝到生产容器

### 4. 修复前端路由和资源加载
- 添加 Vite base path 配置 (/screen/)
- 修复 Vue Router base path 配置
- 修正 Caddyfile 路由顺序,确保 /screen 路径优先匹配

### 5. 修复 TypeScript 编译错误
- LuckyDrawView.vue: 添加 round 属性类型定义
- ProgramCard.vue: 添加非空断言处理

### 6. 修复 SCSS 变量问题
- 替换未定义的 SCSS 变量为硬编码颜色值
- 修复 VoteView、ConnectionStatus、HomeView、ScanLoginView 中的样式问题

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-26 16:59:02 +08:00
empty
4d621b5901 feat: replace Nginx with Caddy for automatic SSL management
- Add Caddyfile with automatic HTTPS configuration
- Add Dockerfile.caddy for frontend build with Caddy
- Update docker-compose.yml to use Caddy service
- Update DEPLOY.md with simplified deployment instructions

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-26 00:28:15 +08:00
empty
d4289825aa feat: add Docker deployment configuration
- Add server Dockerfile with multi-stage build
- Add frontend Dockerfile with Nginx
- Add docker-compose.yml for orchestration
- Add Nginx config with SSL support
- Add deployment documentation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-26 00:23:25 +08:00