Automated scripts to set up and manage Freqtrade trading bots across multiple exchanges using PM2. This repository provides a workflow for deploying and updating Freqtrade bots on various environments including MacOS (brew
), Linux (apt
), and Oracle Linux (dnf
).
This project extensively uses the NostalgiaForInfinityX strategy by iterativv, a popular trading strategy for the Freqtrade crypto bot, known for its robust performance in various market conditions. The strategy is continuously updated and optimized for better results. You can learn more about this strategy and its updates directly from the repository.
Read the exchange specific notes to learn about configurations needed for each exchange, or if trading with leverage is needed.
Follow these steps to quickly set up and start using the Freqtrade management scripts:
-
Clone the Repository 📂
git clone [email protected]:Maxim-Lanskoy/FreqtradeInfinityPM2.git Freqtrade cd Freqtrade
-
Install or Update Dependencies 🔧
Use the
setup-pm2.sh
script to install or update automation-related dependencies (npm
andpm2
):./loader/setup-pm2.sh
-
Install Freqtrade from Scratch 💻
./setup.sh -i
This works for Debian, Ubuntu, Oracle Limux or macOS. This step may take a while!
-
Fill Exchange Related .env Files with Data 💻
sudo nano .env.binance sudo nano .env.kucoin sudo nano .env.gateio sudo nano .env.mexc sudo nano .env.bybit
For each exchange you plan to use, you need to fill in the respective .env file with your API keys and other necessary information.
After that, list needed exchanges in main
.env
file:EXCHANGES=Binance,Kucoin,GateIO,MEXC,ByBit
-
Activate Virtual Environment 🌐
source .venv/bin/activate
-
(Optional) Oracle Linux Fix ⚗️
If running on Oracle Linux system, tweak pm2 service config:
sudo nano /etc/systemd/system/pm2-opc.service
And comment out (
#
) next line:PIDFile=/home/opc/.pm2/pm2.pid
-
Start Your Bots 🚀
Start the Freqtrade bots for each exchange using the
start-pm2.sh
script:cd loader/ ./start-pm2.sh && pm2 stop all
-
Update Bots and Configurations 🔄
Run the
updater.sh
script to check for updates and apply them (chmod
command only needed once):cd loader/ # If not already in loader directory ./updater.sh
This script updates strategies, blacklists, and other configuration files and restarts bots if necessary.
To uninstall specific dependencies related to this repo, like Node.js, npm, and PM2, run the uninstall.sh
script:
./loader/uninstall.sh
Telegram is not mandatory but provides a convenient way to control your bot. More details and the full command list can be found in the documentation.
/start
: Starts the trader./stop
: Stops the trader./profit [<n>]
: Lists cumulative profit from all finished trades, over the last n days./balance
: Show account balance per currency./help
: Show help message./version
: Show version.
The project is currently set up in two main branches:
develop
: This branch is a fork from the original Freqtrade repository.loader
: Contains scripts for installing additional dependencies and automation scripts for the NostalgiaForInfinityX strategy.
To run this bot, we recommend using a cloud instance or machine with the following minimum specifications:
- Hardware: 2GB RAM, 1GB disk space, 2vCPU.
- Software:
For troubleshooting, please refer to the installation documentation page or the NostalgiaForInfinityX strategy page.