- 删除 template-migration.service.ts 文件 - 移除控制器中的迁移相关API接口 (/migrate, /sync, /admin/migration-report) - 清理文档中的迁移服务相关内容 - 添加 data-source.ts 配置文件用于运行数据库迁移 - 模板迁移功能完全通过数据库migration脚本处理
16 lines
455 B
TypeScript
16 lines
455 B
TypeScript
import { DataSource } from 'typeorm';
|
|
|
|
export const AppDataSource = new DataSource({
|
|
type: 'mysql',
|
|
host: 'mysql-6bc9094abd49-public.rds.volces.com',
|
|
port: 53305,
|
|
username: 'root',
|
|
password: 'WsJWXfwFx0bq6DE2kmB6',
|
|
database: 'nano_camera_miniapp',
|
|
entities: ['src/**/*.entity.ts'],
|
|
migrations: ['src/migrations/*.ts'],
|
|
synchronize: false,
|
|
logging: process.env.NODE_ENV === 'development',
|
|
charset: 'utf8mb4',
|
|
timezone: '+08:00',
|
|
}); |