updates related to the BIG Break Changes

This commit is contained in:
2024-07-15 12:35:02 +00:00
parent 16c2cb854e
commit da01b2b587
9 changed files with 106 additions and 95 deletions

View File

@@ -2,9 +2,9 @@
import path from 'path';
import { ConnectionOptions } from 'typeorm';
// import { DataSourceOptions } from 'typeorm';
import { WinstonLogger, RedisSessionCachePlugin, LogLevel, TypeOrmLogger, SystemConfig, DefaultJobQueuePlugin } from '@phoenix/core';
import { WinstonLogger, RedisSessionCachePlugin, LogLevel, TypeOrmLogger, SystemConfig, DefaultJobQueuePlugin, TypeORMHealthCheckStrategy } from '@phoenix/core';
import { AssetServerPlugin } from '@phoenix/asset-server-plugin';
import { ADMIN_API_PATH, API_PORT, SHOP_API_PATH, SUPER_ADMIN_USER_IDENTIFIER } from '@phoenix/common';
import { ADMIN_API_PATH, API_PORT, SHOP_API_PATH, SUPER_ADMIN_USER_IDENTIFIER, WORKER_PORT } from '@phoenix/common';
import { EmailPlugin, FileBasedTemplateLoader, defaultEmailHandlers } from '@phoenix/email-plugin';
//import { BonnAPIPlugin } from '../plugins/bonn-api-plugin/bonn-api-plugin.module';
// import { DefaultJobQueuePlugin } from '@phoenix/system_service';
@@ -15,6 +15,7 @@ import { EmailPlugin, FileBasedTemplateLoader, defaultEmailHandlers } from '@pho
export const customConfig: SystemConfig = {
apiOptions: {
port: API_PORT,
workerPort: WORKER_PORT,
// sslPort: API_SSL_PORT,
//sslCertPath: path.join(__dirname, '../secrets/certificate.crt'),
//sslKeyPath: path.join(__dirname, '../secrets/certificate.key'),
@@ -79,7 +80,7 @@ export const customConfig: SystemConfig = {
db: process.env.REDIS_DB ? parseInt(process.env.REDIS_DB) : 0,
password: process.env.REDIS_PASSWORD || 'admin'
}
}),
}),
AssetServerPlugin.init({
route: 'remote-assets',
assetUploadDir: path.join(__dirname, 'assets'),
@@ -117,6 +118,10 @@ export const customConfig: SystemConfig = {
// port: 5001,
// }),
],
systemOptions: {
healthChecks: [new TypeORMHealthCheckStrategy(null, { key: 'database', timeout: 1000 })],
errorHandlers: [],
},
// ApolloEngineApiKey: "service:Logic-Bits-2900:5w1aCP5YUtF-1ErRG0KNQw"
};