bull-board icon indicating copy to clipboard operation
bull-board copied to clipboard

global prefix doesn't work

Open codeweb05 opened this issue 1 year ago • 8 comments

if I set global prefix on the api, the bull board ui doesn't work

app.setGlobalPrefix('api')

Screenshot from 2023-07-14 16-39-52

codeweb05 avatar Jul 14 '23 11:07 codeweb05

Had a similar problem, but this was fixed in version 5.5.2 (See this PR) Follow this example here. When he sets the base path of the server adapter here Line 58. Update it with your base path (so if it's 'api' like you wrote above then /api/queues and it should work.

Or another way is just modify your app.setGlobalPrefix to have a slash in front so app.setGlobalPrefix('/api') in your case.

Kirkify avatar Jul 14 '23 17:07 Kirkify

~~I'm using the with-nestjs-module example.~~

~~Is it not possible to use the routes & boardOptions in the BullBoardModule.forRoot params along with the global prefix instead of creating a separate module just for config?~~

~~going through the package, this line, implies that global prefix is respected but I get the same loading error too :(~~

I just missed an "s"

VaZark avatar Jul 19 '23 09:07 VaZark

@codeweb05 does @Kirkify response solved your issue?

felixmosh avatar Aug 08 '23 07:08 felixmosh

@codeweb05, does #639 solves your issue?

felixmosh avatar Oct 19 '23 09:10 felixmosh

this issue is still present for me today. I just set the / beforeapi and now it works :)

henrysachs avatar Nov 30 '23 10:11 henrysachs

I have some problem( I use @bull-board/nestjs with fastify

NatashkinAlex avatar Dec 18 '23 14:12 NatashkinAlex

~I'm using the with-nestjs-module example.~

~Is it not possible to use the routes & boardOptions in the BullBoardModule.forRoot params along with the global prefix instead of creating a separate module just for config?~

~going through the package, this line, implies that global prefix is respected but I get the same loading error too :(~

I just missed an "s"

I have the same problem when using nestjs with fastify adapter, global prefix and nestjs bull board module. Can you show me how you fix this ?

vvtri avatar Jan 04 '24 03:01 vvtri

I have this same issue when using fastify.

Adding / before api does not fix the issue for fastify, it might fix it for express only.

Seems related to this line where on the fastify adapter we are overriding the prefix option.

PR #639 does resolve the issue for me though.

selabie68 avatar Jan 22 '24 06:01 selabie68

have this same issue when using fastify.

my plan is using pnpm patch to modity the package.

Ttou avatar Feb 01 '24 15:02 Ttou

@codeweb05, can you check if #704 solves this issue?

felixmosh avatar Mar 24 '24 08:03 felixmosh