Skip to content

Instantly share code, notes, and snippets.

@smurugap
Last active April 27, 2020 01:53
Show Gist options
  • Save smurugap/6b8e7ee3bde3fd81a31700362e9b2c1f to your computer and use it in GitHub Desktop.
Save smurugap/6b8e7ee3bde3fd81a31700362e9b2c1f to your computer and use it in GitHub Desktop.
sample haproxy container
Create /tmp/haproxy.cfg file:
global
daemon
defaults
log global
frontend contrail_webui_external
bind 10.87.69.7:8143
mode tcp
default_backend webui_backend
backend webui_backend
mode tcp
server server1 10.87.69.8:8143 check
Execute the below commands which will start the haproxy container:
docker pull haproxy
docker run -it --rm --privileged --network host --name myhaproxy -v /tmp/haproxy.cfg:/tmp/haproxy.cfg haproxy haproxy -f /tmp/haproxy.cfg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment