You can run Rocket.Chat for development on a Linux machine or VM. The following instruction has been tested on a new Ubuntu 18.04 LTS installation. Try to find and use a NEW Ubuntu server installation with no other un-necessary software installed, not a "Desktop" or "Client" installation.
DO NOT use a system where you already have nodeJS installed to avoid problems.
During the build, memory usage will be nearly 8G, this is the minimum level of RAM recommended for development workstations. (If you are not doing any development, and just deploying a Rocket.Chat server - the RAM required can be as low as 1G.)
IMPORTANT: Note that there is no need to install mongo, nodejs, or npm on the base operating system. If you have any of these already installed; start over, or use another CLEAN system.
Development should be performed under a regular user account (not root) on Linux. There should be no need to run sudo at all. Running sudo, even once, during the installation -- may mess up file permissions in irreversible manner.
You may notice build WARNINGs related to peer dependencies or other transitive dependencies. They are typically safe to ignore unless you are coding the feature or modules that require them.
(If you are using other OS (like Ubuntu 20.04 etc) you may run into an error "python-minimal has no installation candidate") To resolve this you can go to Python Minimal error
curl https://install.meteor.com/ | sh
(Under some circumstances, you may need to install a specific (older) release of Meteor instead of the latest, always check the .meteor/release file of the Github code repository to determine if you need to do this before you install meteor)
There is no need to install node or npm, as meteor already includes them. Verify by:
Editing files is relatively simple. After you run git clone, the files from the repository are saved on your computer. You can go to the cloned repository folder and edit or add files to Rocket.Chat. When you make changes to Rocket.Chat the server will automatically rebuild.
Sometimes changes can shut down the server, if that happens just run meteor npm start again.
The Rocket.Chat code base is very large. You may need to increase this system parameter on your operating system for the files-change watcher to operate efficiently.
Using Windows to develop is not recommended at this time, instead is better to create a Linux virtual machine and follow the steps mentioned above, but if for some reason you really need to build Rocket.Chat on Windows you can find a community supported guide over here.
We look forward to the official release of Windows Subsystem for Linux 2 (WSL 2) when Rocket.Chat development on Linux may finally become viable.