Closed toczke closed 2 years ago
Hey ! Nice thanks 🙂
Hello, Thanks for the project and the contribution!
I tried building and running with Docker but it's not working for me. Does it work for you guys? This is my stacktrace:
❯ docker run -p 3000:3000 -it saveriogzz/toogoodtogobot
yarn run v1.22.19
$ ts-node ./dist/src/index.js
node:internal/modules/cjs/loader:959
throw err;
^
Error: Cannot find module './index.js'
Require stack:
- /app/dist/src/imaginaryUncacheableRequireResolveScript
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:956:15)
at Function.resolve (node:internal/modules/cjs/helpers:108:19)
at requireResolveNonCached (/app/node_modules/ts-node/dist/bin.js:489:16)
at getProjectSearchDir (/app/node_modules/ts-node/dist/bin.js:459:40)
at phase3 (/app/node_modules/ts-node/dist/bin.js:263:27)
at bootstrap (/app/node_modules/ts-node/dist/bin.js:44:30)
at main (/app/node_modules/ts-node/dist/bin.js:32:12)
at Object.<anonymous> (/app/node_modules/ts-node/dist/bin.js:519:5)
at Module._compile (node:internal/modules/cjs/loader:1126:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1180:10) {
code: 'MODULE_NOT_FOUND',
requireStack: [ '/app/dist/src/imaginaryUncacheableRequireResolveScript' ]
}
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
I'm not a TS or JS person, but I guess it's failing because it does not find the file ./index.js
(which I believe it's changed to be .ts
)!
Let me know what you think and if I can help! :)
Hey, I've created dockerfile to run app in container for ease of use.