Language Support
Node
Language Support
Node
Deploy Node.js applications with Hop
Hop uses Nixpacks for automatic, configless
deployments. You can write a custom Dockerfile
if you don’t want to use
Nixpacks.
Node.js is detected when you have a package.json
file in your project. All dependencies found in packages.json
are installed with either NPM, Yarn, PNPM, or Bun (depending on the lockfile detected).
Start Command
You can specify a custom start command in your package.json
file, for example:
package.json
{
"scripts": {
"start": "node index.js"
}
}
If not specified, then the start command will be inferred based on the environment. Read more on the Nixpacks documentation.
Versions
Hop supports the following Node.js versions out of the box:
- 18
- 16 (default)
- 14
Specifying a version
The version can be overridden by:
- Setting the
NIXPACKS_NODE_VERSION
environment variable, or - Specifying the
engines.node
field inpackage.json