Skip to content

Installation and startup

voyz edited this page Nov 2, 2020 · 9 revisions

Installation

Docker image (recommended):

docker pull voyz/ibeam

Standalone:

pip install ibeam

Startup

Using Docker image (recommended)

IBeam's Docker image is configured to work out of the box. Run the IBeam image exposing the port 5000 and providing the environment variable credentials either directly or through a file.

Using env.list file:

docker run --env-file env.list -p 5000:5000 voyz/ibeam

Providing environment variables directly:

docker run --env IBEAM_ACCOUNT=your_account123 --env IBEAM_PASSWORD=your_password123 -p 5000:5000 voyz/ibeam

Verify the Gateway is running inside of the container by calling:

curl -X GET "https://localhost:5000/v1/api/one/user" -k

Standalone

The entrypoint of IBeam is the ibeam_starter.py script. When called without any arguments, the script will start the Gateway (if not currently running) and will attempt to authenticate (if not currently authenticated).

python ibeam_starter.py

Following exclusive flags can be provided when running the starter script:

  • -a, --authenticate - Authenticate the currently running gateway.
  • -k, --kill - Kill the gateway.
  • -m, --maintain - Maintain the gateway.
  • -s, --start - Start the gateway if not already running.
  • -t, --tickle - Tickle the gateway.
  • -u, --user - Get the user info.
  • -l, --validate - Validate authentication.

Additionally the following flag can be supplied with any other flags to log additional runtime information:

  • -v, --verbose - More verbose output.

Verify the Gateway is running as standalone by calling:

curl -X GET "https://localhost:5000/v1/api/one/user" -k

You will need additional environment requirements to run IBeam standalone. Read more about it in Standalone Environment

Once started

Once the Gateway is running and authenticated you can communicate with it like you would normally. Please refer to Interactive Brokers' documentation for more.

Clone this wiki locally