Step-by-Step Guide to Configuring and Launching TBOT with a Live IB Account in Docker
Background
When attempting to connect to an IB Gateway account with a Live account, it's important to note that TBOT on TradingBoat is primarily designed for educational purposes. It is advisable to familiarize yourself thoroughly with its features using a Paper Account before progressing to a Live Account.
Using TBOT on TradingBoat for an IB Live account comes with potential financial risks. These include possible operational failures of TBOT due to the software's inherent characteristics.
Step-by-Step Guide
This guide will help you enable an IB Gateway Live Account within the TBOT on TradingBoat container. This process is also covered in the Udemy Course "Simple and Fast Trading Robot Setup with Docker, TradingView." Simple and Fast Trading Robot Setup with Docker, TradingView
Updating Environment Variables
Please modify the following four parameters in your .env file:
TWS_USERID=RealUser
TWS_PASSWORD=RealPassword
TRADING_MODE=live
TBOT_IBKR_PORT=4001
Firist three variables are coming from GitHub - UnusualAlpha/ib-gateway-docker: Docker image with IB Gateway and IBC
The fourth variable is specific to TBOT. More information about this can be found in the course materials.
Initiating Containers
Once you've updated these values, begin the container initiation process with the following command:
docker-compose build --no-cache
For this demonstration, I am running the containers in non-detached mode to display the console messages, as shown in the subsequent picture. However, in practice, you may choose to run the containers in detached mode, if preferred.
To start the containers, use:
docker-compose up
Once you run the containers (without detached mode), you will see a message indicating “Second Factor Authentication initiated,” as shown in the above picture.
Second Factor Authentication from IBKR
If you login the container with VNC View , you will see the message from IBKR, it will ask you to got IBKR App on your phone as like the following picture to confirm Second Factor Authentication.
You shall confirm the authentication from your IBKR App on your phone.
Verifying Connection from TBOT Webpage
Upon confirming the authentication on your phone, TBOT on TradingBoat will operate similarly to paper mode. Once the connection is successfully established, visit the Error Page (http://127.0.0.1:5000/errors) to verify your connection, as demonstrated in the following images.
Further details and procedures, I highly recommend referring to the comprehensive Udemy course available here: Link to Udemy Course.