1000 FAQs, 500 tutorials and explanatory videos. Here, there are only solutions!
This guide explains how to use Node.js with a managed Cloud Server.
Installing Node.jsYou can install NVM from your admin console, by following our guide: https://faq.infomaniak.com/23
To install Node.js via NVM:
To start the loop server (server.js contains server.listen(3000)):
forever start server.js
To redirect apache traffic to the backend of Node.js, add this to your .htaccess file:
RewriteRule ^(.*)$ http://localhost:3000/$1 [L,P]
Changing versions of Node.js
Set 6.1.0 (or another version) as default
nvm alias default 6.1.0