fix: twentyORM datasource configuration for ssl (#5529)

We need to specify ssl configuration for TwentyORM datasources when
needed, otherwise connection will be broken.
This commit is contained in:
Jérémy M
2024-05-22 11:11:05 +02:00
committed by GitHub
parent 474dfd7bd8
commit bb6df43d17

View File

@@ -38,6 +38,11 @@ export class WorkspaceDatasourceFactory {
logging: 'all',
schema: dataSourceMetadata.schema,
entities,
ssl: this.environmentService.get('PG_SSL_ALLOW_SELF_SIGNED')
? {
rejectUnauthorized: false,
}
: undefined,
});
await workspaceDataSource.initialize();