R
Railway7mo ago
Oren

Node lts support

I configured package.json to use current lts version of node (20.9.0) but observing this warning WARN  Unsupported engine: wanted: {"node":"20.9.0"} (current: {"node":"v20.6.1","pnpm":"8.10.4"}) package.json config: "engines": { "node": "20.9.0" },
6 Replies
Percy
Percy7mo ago
Project ID: 63395696-9942-498c-b3e6-8f00f515718f
Oren
Oren7mo ago
63395696-9942-498c-b3e6-8f00f515718f
jeremy
jeremy7mo ago
Node | Nixpacks
App source + Nix packages + Docker = Image
jeremy
jeremy7mo ago
if you use the default builder nixpacks
Oren
Oren7mo ago
@jeremy yes I'm already specifying the engines.node field in package.json but the problem is railway/nixpacks supports v20.6.1 as highest version today which is not lts, would be nice to bump this to 20.9.0 aka latest lts
Brody
Brody7mo ago
nixpacks only supports specifying major versions, to use a specific version you can specify the archive to use, create a nixpacks.toml file in your project with this in it
[phases.setup]
nixpkgsArchive = '11011277cb654f9acd29072fc977f5793bf88121'
[phases.setup]
nixpkgsArchive = '11011277cb654f9acd29072fc977f5793bf88121'
reference: https://github.com/NixOS/nixpkgs/commit/11011277cb654f9acd29072fc977f5793bf88121