Function server_forge::deployment::deploy_nodejs
source · pub fn deploy_nodejs() -> Result<(), Box<dyn Error>>
Expand description
Deploys and configures Node.js.
This function installs Node.js using NVM (Node Version Manager), installs the latest LTS version, and sets it as the default. It also installs the PM2 process manager for running Node.js applications.
§Returns
Returns Ok(())
if Node.js is deployed successfully, or an error if deployment fails.