Installation

You will need to install some packages if you're using Linux/Ubuntu/CentOS/AlmaLinux. Then you can install the TrafficForge Worker package.

Automatic Installation

This automatic installation only for Linux Operating System. You can install the required package using the following command:

bash
curl -fsSL https://cdn.rankforge.io/scripts/install.sh | bash

Manual Installation

Linux/Ubuntu Packages

apt
sudo apt install git ca-certificates fonts-liberation libasound2 libatk-bridge2.0-0 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgbm1 libgcc1 libglib2.0-0 libgtk-3-0 libnspr4 libnss3 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 lsb-release wget xdg-utils -y

CentOS/AlmaLinux Packages

yum
yum install git alsa-lib.x86_64 atk.x86_64 cups-libs.x86_64 gtk3.x86_64 libXcomposite.x86_64 libXcursor.x86_64 libXdamage.x86_64 libXext.x86_64 libXi.x86_64 libXrandr.x86_64 libXScrnSaver.x86_64 libXtst.x86_64 pango.x86_64 xorg-x11-fonts-100dpi xorg-x11-fonts-75dpi xorg-x11-fonts-cyrillic xorg-x11-fonts-misc xorg-x11-fonts-Type1 xorg-x11-utils -y && yum update nss -y

MacOS

Install Homebrew if not already installed

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Install required packages

brew install git wget cairo pango glib gtk+3 nspr nss dbus

Install fonts

brew tap homebrew/cask-fonts
brew install --cask font-liberation

Install XQuartz (X11)

brew install --cask xquartz

Windows

Download NodeJS & Git directly from the official site then install it. Use NodeJS version 18 or higher.

Install NodeJS via NVM

  1. Install Node Version Manager (NVM):
cURL
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
wget
wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
  1. Export NVM_DIR and source it in your shell:
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 nvm
  1. Install NodeJS 20 LTS:
nvm install 20 --lts

Install TrafficForge Worker

Then you can easily install our traffic-worker package:

npm
npm i --global @rankforge/traffic-worker

Install PM2 (optional)

If you want to use PM2 to manage your traffic-worker, you can install it with:

npm
npm i --global pm2
✨ Well done! You can now run your Worker on your local device or VPS.