java.lang.Object
io.jooby.node.NodeModule
- All Implemented Interfaces:
io.jooby.Extension
- Direct Known Subclasses:
NpmModule,YarnModule
Base class for Npm and Yarn installer.
- Since:
- 2.8.0
- Author:
- edgar
-
Method Summary
Modifier and TypeMethodDescriptionExecute a node task (without blocking the caller thread).executeOnce(String cmd, String... args) Run a task once per JVM instance.voidinstall(io.jooby.Jooby application) installDirectory(Path installDirectory) Set install directory where to save the node executable (node/node).workDirectory(Path workDirectory) Set working directory (location of package.json).Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.jooby.Extension
lateinit
-
Method Details
-
workDirectory
Set working directory (location of package.json).- Parameters:
workDirectory- Work directory.- Returns:
- This module.
-
installDirectory
Set install directory where to save the node executable (node/node).- Parameters:
installDirectory- Location where to save the node executable (node/node).- Returns:
- This module.
-
execute
Execute a node task (without blocking the caller thread).- Parameters:
cmd- Command.args- Arguments.- Returns:
- This module.
-
executeOnce
Run a task once per JVM instance. Specially created for joobyRun to supports application restart (hot reload) and long running node processes (like a web server).- Parameters:
cmd- Command.args- Arguments.- Returns:
- This module.
-
install
- Specified by:
installin interfaceio.jooby.Extension- Throws:
Exception
-