Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save deanpeterson/2e5a12a9edbc61201338247d437eed78 to your computer and use it in GitHub Desktop.
Save deanpeterson/2e5a12a9edbc61201338247d437eed78 to your computer and use it in GitHub Desktop.
nestjs deployment errors
Environment:
DEV_MODE=false
NODE_ENV=production
DEBUG_PORT=5858
Launching via npm...
npm info it worked if it ends with ok
npm info using npm@6.14.15
npm info using node@v14.18.2
npm info lifecycle @my-app/server@~prestart: @my-app/server@
npm info lifecycle @my-app/server@~start: @my-app/server@
> @my-app/server@ start /opt/app-root/src
> nest start
src/auth/basic/base/basic.strategy.base.ts:3:43 - error TS7016: Could not find a declaration file for module 'passport-http'. '/opt/app-root/src/node_modules/passport-http/lib/passport-http/index.js' implicitly has an 'any' type.
Try `npm i --save-dev @types/passport-http` if it exists or add a new declaration (.d.ts) file containing `declare module 'passport-http';`
3 import { BasicStrategy as Strategy } from "passport-http";
   ~~~~~~~~~~~~~~~
src/auth/gqlDefaultAuth.guard.ts:3:30 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
3 import type { Request } from "express";
   ~~~~~~~~~
src/auth/jwt/base/jwt.strategy.base.ts:3:38 - error TS7016: Could not find a declaration file for module 'passport-jwt'. '/opt/app-root/src/node_modules/passport-jwt/lib/index.js' implicitly has an 'any' type.
Try `npm i --save-dev @types/passport-jwt` if it exists or add a new declaration (.d.ts) file containing `declare module 'passport-jwt';`
3 import { ExtractJwt, Strategy } from "passport-jwt";
   ~~~~~~~~~~~~~~
src/auth/password.service.ts:2:31 - error TS7016: Could not find a declaration file for module 'bcrypt'. '/opt/app-root/src/node_modules/bcrypt/bcrypt.js' implicitly has an 'any' type.
Try `npm i --save-dev @types/bcrypt` if it exists or add a new declaration (.d.ts) file containing `declare module 'bcrypt';`
2 import { hash, compare } from "bcrypt";
   ~~~~~~~~
src/card/base/Card.ts:18:27 - error TS2307: Cannot find module 'type-fest' or its corresponding type declarations.
18 import { JsonValue } from "type-fest";
   ~~~~~~~~~~~
src/card/base/card.controller.base.ts:18:25 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
18 import { Request } from "express";
   ~~~~~~~~~
src/health/base/health.controller.base.ts:2:26 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
2 import { Response } from "express";
   ~~~~~~~~~
src/player/base/Player.ts:16:27 - error TS2307: Cannot find module 'type-fest' or its corresponding type declarations.
16 import { JsonValue } from "type-fest";
   ~~~~~~~~~~~
src/player/base/player.controller.base.ts:18:25 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
18 import { Request } from "express";
   ~~~~~~~~~
src/playerCard/base/playerCard.controller.base.ts:18:25 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
18 import { Request } from "express";
   ~~~~~~~~~
src/specialAbility/base/specialAbility.controller.base.ts:18:25 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
18 import { Request } from "express";
   ~~~~~~~~~
src/types.ts:1:27 - error TS2307: Cannot find module 'type-fest' or its corresponding type declarations.
1 import { JsonValue } from "type-fest";
   ~~~~~~~~~~~
src/user/base/user.controller.base.ts:18:25 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
18 import { Request } from "express";
   ~~~~~~~~~
src/user/user.controller.ts:6:25 - error TS7016: Could not find a declaration file for module 'express'. '/opt/app-root/src/node_modules/express/index.js' implicitly has an 'any' type.
If the 'express' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/express'
6 import { Request } from "express";
   ~~~~~~~~~
src/util/JsonNullableFilter.ts:1:27 - error TS2307: Cannot find module 'type-fest' or its corresponding type declarations.
1 import { JsonValue } from "type-fest";
   ~~~~~~~~~~~
Found 15 error(s).
npm info lifecycle @my-app/server@~start: Failed to exec start script
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @my-app/server@ start: `nest start`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @my-app/server@ start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm timing npm Completed in 3102ms
npm ERR! A complete log of this run can be found in:
npm ERR! /opt/app-root/src/.npm/_logs/2022-06-07T17_39_28_469Z-debug.log
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment