Open vincentpham13 opened 4 years ago
Is your consul started?
I am having this same issue, can't trace where the error is from, mostly from the consul and Service Discovery
[Nest] 28400 - 11/09/2020, 12:36:22 PM [ExceptionHandler] Cannot find module 'consul'
Require stack:
- /srv/server/node_modules/@nestcloud/consul/consul.module.js
- /srv/server/node_modules/@nestcloud/consul/index.js
- /srv/server/dist/apps/service-notification/main.js +6ms
Error: Cannot find module 'consul'
Require stack:
- /srv/server/node_modules/@nestcloud/consul/consul.module.js
- /srv/server/node_modules/@nestcloud/consul/index.js
- /srv/server/dist/apps/service-notification/main.js
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:966:15)
at Function.Module._load (internal/modules/cjs/loader.js:842:27)
at Module.require (internal/modules/cjs/loader.js:1026:19)
at require (internal/modules/cjs/helpers.js:72:18)
at InstanceWrapper.useFactory [as metatype] (/srv/server/node_modules/@nestcloud/consul/consul.module.js:41:32)
at Injector.instantiateClass (/srv/server/node_modules/@nestjs/core/injector/injector.js:293:55)
at callback (/srv/kpilens/server/node_modules/@nestjs/core/injector/injector.js:77:41)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async Injector.resolveConstructorParams (/srv/server/node_modules/@nestjs/core/injector/injector.js:118:24)
at async Injector.loadInstance (/srv/server/node_modules/@nestjs/core/injector/injector.js:81:9)
[System Information] OS Version : macOS Catalina NodeJS Version : v10.0.0 YARN Version : 1.22.1
[Nest CLI] Nest CLI Version : 7.1.4
[Nest Platform Information] platform-express version : 7.4.2 microservices version : 7.4.2 terminus version : 7.0.1 testing version : 7.4.2 common version : 7.4.2 core version : 7.4.2
I just cloned the
nestcloud-grpc-example
then upgraded all the nest-cloud modules to the latest versions. but unfortunately, it does not work even if I did not upgrade the version of the modules. here is my terminal logs