Failing to deploy nextjs app with sharp / node-canvas

canastroHOBBY

7 months ago

Im trying to use Nixpacks to pre-install some python deps that node-canvas requires:

NIXPACKS_PKGS="python313 pkg-config cairo pango libpng giflib librsvg pixman"

But Im getting the following error:

Package pixman-1 was not found in the pkg-config search path.

Has anyone successfuly deployed a next.js app with sharp installed? I keep getting diferent errors with node-gyp (with this being the last one that I couldnt figure out how to fix)

0 Replies

canastroHOBBY

7 months ago

28fb16ab-96f2-4c97-a9fe-a70ac8d2d11f


7 months ago

I would have to recommend you go with a dockerfile instead of nixpacks


canastroHOBBY

7 months ago

yeah, thats what I ended-up doing. Good to have some validation. Thanks


Failing to deploy nextjs app with sharp / node-canvas - Railway Help Station