Skip to content

Commit

Permalink
fix(be): 🔥 drop support bull board for serverless function
Browse files Browse the repository at this point in the history
  • Loading branch information
lehuygiang28 committed Jul 2, 2024
1 parent 1929d2c commit ce71983
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 9 deletions.
4 changes: 0 additions & 4 deletions apps/be/src/app/middlewares/job-queues.middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,6 @@ export function jobQueueUIMiddleware(connection: Redis, basePath = '') {
createBullBoard({
queues,
serverAdapter,
options: {
uiBasePath: require.resolve(`@bull-board/ui/package.json`).replace('package.json', ''),
uiConfig: {},
},
});

return serverAdapter.getRouter();
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
"@ant-design/nextjs-registry": "^1.0.0",
"@bull-board/api": "^5.20.5",
"@bull-board/express": "^5.20.5",
"@bull-board/ui": "^5.20.5",
"@faker-js/faker": "^8.4.1",
"@hookform/resolvers": "^3.4.2",
"@kovalenko/is-cron": "^1.0.10",
Expand Down
5 changes: 3 additions & 2 deletions serverless/api/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ const tsConfigPaths = require('tsconfig-paths');
const tsConfig = require('./tsconfig.json');

/**
* Import the modules that serverless couldn't find in node_modules
* Import some modules that serverless couldn't find it
*/
require('@bull-board/ui/package.json');

/* ... */

const baseUrl = tsConfig?.compilerOptions?.baseUrl ?? '../';

Expand Down
3 changes: 1 addition & 2 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1879,7 +1879,7 @@ __metadata:
languageName: node
linkType: hard

"@bull-board/ui@npm:5.20.5, @bull-board/ui@npm:^5.20.5":
"@bull-board/ui@npm:5.20.5":
version: 5.20.5
resolution: "@bull-board/ui@npm:5.20.5"
dependencies:
Expand Down Expand Up @@ -5066,7 +5066,6 @@ __metadata:
"@babel/core": "npm:^7.24.6"
"@bull-board/api": "npm:^5.20.5"
"@bull-board/express": "npm:^5.20.5"
"@bull-board/ui": "npm:^5.20.5"
"@compodoc/compodoc": "npm:^1.1.25"
"@faker-js/faker": "npm:^8.4.1"
"@hookform/resolvers": "npm:^3.4.2"
Expand Down

0 comments on commit ce71983

Please sign in to comment.