I recently started a course on microservices and ran into a problem with the application of the passport. The problem is that my strategy apparently does not see my token and does not call the validate method. After reading the articles, I realized that this may be due to the fact that my token is not valid and his time ran out, but I checked this case. I will leave all the photos of my services, the structure below. I will also add a link to git. Thank you in advance
JWTStrategy seems like this: enter image description here
My login method(rmq): enter image description here
App module: enter image description here
RMQ service: enter image description here
problem like this:enter image description here link to github: click .
// from:
jwtFromRequest: ExtractJwt.fromAuthHeaderAsBearerToken,
//to:
jwtFromRequest: ExtractJwt.fromAuthHeaderAsBearerToken()
providers: [JwtStrategy]
// from:
return ctx.switchToHttp().getRequest()?.user;
//to:
return ctx.switchToHttp().getRequest()?.user?.id;
My issue with same answer: https://github.com/AlariCode/6-microservices-demo-1/issues/1
My implementation: https://github.com/Rudimo/nx-nest-microservices-rmq-demo