Railway deployment fails with "node-gyp-build error"
Hello, am new on railway and i am getting these errors when i try to deploy my nodejs express API, but everything work well on local and other servers. Can someone help me with this please ?
Last Deployment Id: 01044eee-19e1-41f5-b965-915b144982f4
Project id : f083e293-6fa8-47f0-8d44-d5c5f4341a8a
Build logs:
16 Replies
Project ID:
01044eee-19e1-41f5-b965-915b144982f4,f083e293-6fa8-47f0-8d44-d5c5f4341a8a
please use this to send your logs https://bookmarklets.up.railway.app/log-downloader/
try adding a nixpacks.toml file to your project with this in it
Get this error now :
progress
yes, sure
updated this
if you could provide your repo that would help a lot
it looks like youre trying to install this npm package? https://www.npmjs.com/package/usb
there arent going to be any usb devices available when on railway, can you share why you are using this package?
am not using this package, maybe one of my lib are using it.
Can u give me your github username, i'll add you to the repo if you want
Get this error when trying your last suggestion
brody192
I've added you to the repository, the usb error comes from the
aleph-sdk-ts
module, because when I remove it everything seems to work. Thanks for your helpah okay cool, if you can, don't use modules that are dependent on usb libraries, you wouldn't be able to access any usb devices on a hosted environment like railway
I really need this package for my project, how can i use it without theses errors and usb problems ?
this is very likely the package that is needing the usb system library https://www.npmjs.com/package/@ledgerhq/hw-transport-webusb
it's listed in the dependencies of
aleph-sdk-ts
, do you use this functionality?No, I don't use this functionality in my project