The instance I’m working with was created on Google Cloud, which doesn’t enable SSH login by default. To keep server management in one place, I use Termius.
Enabling SSH Login
- Open the terminal through the built-in SSH window

- Set a password for the root user
# Switch to the root usersudo -i# Set the passwordpasswd- Edit
PermitRootLoginandPasswordAuthenticationin the sshd_config file
vi /etc/ssh/sshd_config
- Restart the server
- Log in with Termius

Once logged in, you should see something like this

Installing nvm
1. Update system packages
First, make sure your system packages are up to date:
sudo apt updatesudo apt upgrade -y2. Install NVM
You can install NVM from its GitHub repository with the following command:
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bashNote that v0.39.7 is the NVM version number — check NVM’s GitHub page for the latest release.
3. Load NVM
After installation, load NVM into your shell session:
export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvmTo load NVM automatically every time a shell starts, append the commands above to your shell config file such as ~/.bashrc, ~/.zshrc, or ~/.profile:
echo 'export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"' >> ~/.bashrcecho '[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"' >> ~/.bashrcThen reload the shell config:
source ~/.bashrc4. Verify the NVM installation
Check that NVM was installed successfully:
nvm -v
5. Install Node.js
Install the latest LTS version of Node.js with NVM:
nvm install --ltsYou can also install a specific version, for example:
nvm install 14.17.06. Set the default Node.js version
Use the following commands to set a default version:
# List installed Node versionsnvm list# Set the default versionnvm alias default 14.17.07. Verify Node.js and npm
Finally, confirm that Node.js and npm are installed:
node -vnpm -v
Installing MongoDB 6
- Add the repository for Ubuntu:
echo "deb [ arch=amd64,arm64 signed-by=/usr/share/keyrings/mongodb-server-6.0.gpg ] https://repo.mongodb.org/apt/ubuntu jammy/mongodb-org/6.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-6.0.list- Add the signing key
curl -fsSL https://pgp.mongodb.com/server-6.0.asc | \ sudo gpg -o /usr/share/keyrings/mongodb-server-6.0.gpg \ --dearmor- Update apt and install MongoDB
sudo apt update && sudo apt install mongodb-org -y- Start the MongoDB service
Once installation finishes, start the service
sudo systemctl start mongod- Enable MongoDB on boot
Make the MongoDB service start automatically with the system
sudo systemctl enable mongod- Verify the installation
Check the service status to make sure it’s running
sudo systemctl status mongodOutput like the following means MongoDB is up and running

Installing Git
- Update the APT package database
First, make sure your APT package database is current
sudo apt update- Install Git
sudo apt install git -y- Verify the installation
Once it’s done, confirm Git works
git -vInstalling PM2
With Node.js and npm in place, install PM2 globally
npm install -g pm2Start your Node.js project with PM2. For example, if the entry file is main.js
pm2 start main.js --name "steam-shared-service"Verify the project is running
Hit one of the service’s endpoints with Apifox
