Closed nrobinaubertin closed 1 year ago
Might be related to https://github.com/canonical/rockcraft/issues/307
The message is a bit opaque but it's meant to say that you should provide a node
binary; This can be a stage-package, or snap, or a specific version downloaded "manually" via override-build.
So to use the npm-plugin, I need to provide a node binary ? I didn't understand that reading the doc. I would suggest adding a line about that if it's the case
@nrobinaubertin rockcraft should be the same as snapcraft's core22 support on this front, since they both use the craft-parts npm plugin.
You can provide npm as @tigarmo suggested above, or you can set npm-node-version
(and optionally npm_include_node
), similar to how it's done in traefik-rock. The meanings are the same as what's listed in the core22
section of the snapcraft doc you linked.
I've updated the docs to provide some more clarity. It may take a bit of time for the update to make its way into production, but ITMT you can view the edited version on the snapcraft forum. This won't necessarily be 100% identical since rockcraft and snapcraft do differ in a few ways, but relevant to your question it should be the same. Feel free to reopen if not!
Bug Description
I try to use the npm plugin in its most basic form and packing fails.
To Reproduce
Just rockcraft pack the rockfile. Proposed here with ubuntu:22.04 but also fails with ubuntu:20.04
Environment
rockcraft.yaml
Relevant log output