nest 5.x升nest 8.x 中遇到的问题,sqlserver 链接需要ssl认证,nest7好像有警告。
解决方法:在数据库配置 options加入 trustServerCertificate:true
const dbconfig = { type: 'mssql', host: '***.***.*.***', database: 'testdb', password: '****', port: 1433, username: '**', logging: true, entities: [User, Role, Group, ClientSystem, ClientLogin, ClientAddress, SystemLog, SystemDepartment, SystemHospital, ClientExtendParam, ClientParams, LoginLog] , synchronize: false, extra:{ trustServerCertificate:true } };