ryankennedyio / ib-docker

Dockerized interactive brokers gateway
98 stars 26 forks source link

ib ports #5

Closed bradywood closed 7 years ago

bradywood commented 7 years ago

Hi, first awesome work on getting the ibgateway working in noninteractive mode.

I am trying to work out how the port redirect works, as when I docker exec onto the container I can see something listening on 4003 but nothing on 4001 which currently the socat redirects/forks to.

I noted that IBGateway is started on 7642 by default, is this the port that 4003 should be redirecting to?

eg.. instead of socat TCP-LISTEN:4003,fork TCP:127.0.0.1:4001

this socat TCP-LISTEN:4003,fork TCP:127.0.0.1:7642

Can someone assist with clearing up my port understanding I think its in the ini config, but I am a bit unsure.

bradywood commented 7 years ago

Ahh. The issue is if you don't set the correct credentials in both the IBController.ini and the docker-compose.yml that it doesnt actually start the IBController correctly.

I have also noticed on occasions that even with the correct TWSUSERID in both files, the controller sometimes on first start fails to comeup.. Using the scaling option of docker-compose scale =0 and then docker-compose scale =1 things will again work.

not sure why yet. still investigating.