/luIP-marzban-node

LuIP-marzban node version

Primary LanguageJavaScriptMIT LicenseMIT

luIP-marzban-node

LuIP-marzban node version

Installation

If you don't have node.js installed on your server, install it with nvm

Install Node.js

  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
  source ~/.bashrc
  nvm install --lts

Install other requirements

  sudo apt-get install -y iptables
  sudo apt-get install gawk
  sudo apt-get install csvtool
  npm install pm2 -g

Install luIP-marzban

  git clone https://github.com/mmdzov/luIP-marzban-node.git
  cd luIP-marzban-node
  cp .env.example .env
  npm install

luIP-marzban-node/.env file

  # Open the project folder, then execute the follow command
  nano .env

Provider configuration

Parameter Description
PROVIDER_ADDR Enter the main server address. e.g: https://sub.example.com:3000 or https://example.com:3000. Port 3000 is the default port of luIP-marzban server.
PROVIDER_API_LOGIN Set this value equal to the value of the API_LOGIN variable located in the env file of luIP-marzban.
PROVIDER_API_PATH Set this value equal to the value of the API_PATH variable located in the env file of luIP-marzban.
PROVIDER_LISTEN_PATH Set this value equal to the value of the LISTEN_PATH variable located in the env file of luIP-marzban.

Permission to use ipban.sh && ipunban.sh

In order for the file to work, permission must be obtained to use it

  # Open the project folder, then execute the follow command
  chmod +x ./ipban.sh
  chmod +x ./ipunban.sh
  chmod +x ./restore_banned_ips.sh

Run the project

After configuring the project, run it

  # Open the project folder, then execute the follow command
  npm start

Note

  1. On the main server, in the .env file located in luIP-marzban, the value of the API_ENABLE variable must be true.