1. Download Node.js
Buka browser di RDP dan download Node.js:
https://nodejs.org/en/download/
Pilih Windows Installer (.msi) versi LTS, lalu jalankan installer.
2. Install Node.js
- • Double-click file installer yang sudah di-download
- • Klik Next dan Accept License Agreement
- • Pilih default installation path (C:\Program Files\nodejs)
- • Centang "Automatically install necessary tools" jika ada
- • Klik Install dan tunggu selesai
3. Verifikasi Instalasi
Buka Command Prompt (CMD) atau PowerShell:
node -v
npm -v
4. Clone dan Jalankan Bot
Buka CMD, navigasi ke folder dan clone repository:
cd C:\Users\YourUsername\Desktop
git clone https://github.com/username/bot-repo.git
cd bot-repo
npm install
Jalankan bot:
node index.js
5. Run Bot in Background (PM2)
Install PM2 untuk menjalankan bot di background:
npm install -g pm2
pm2 start index.js --name "mybot"
pm2 save
💡 Tips untuk RDP
- • Jangan tutup CMD jika tidak menggunakan PM2
- • Gunakan PM2 agar bot tetap jalan setelah disconnect
- • Set PM2 untuk auto-start:
pm2-startup install