Docker Community Forums

Share and learn in the Docker community.

Dockercloud/haproxy for tcp only

dockercloud

(Martolini) #1

I can’t seem to figure out how to load balance a pure tcp server, hopefully someone here can help.

My stackfile is pretty simple;

lb-master:
  environment:
    - MODE=tcp
  image: 'dockercloud/haproxy:latest'
  links:
    - master
  ports:
    - '8484:8484'
  roles:
    - global
master:
  ports:
    - '8484'
  image: 'martolini/maple-load-test:latest'

And the master image is simply a require('net').createServer().listen(8484).
I’ve also tried to add TCP_PORTS=8484 to lb-masters environment with no luck.