summaryrefslogtreecommitdiffstats
path: root/roles/openshift_loadbalancer
diff options
context:
space:
mode:
authorScott Dodson <sdodson@redhat.com>2017-12-06 16:38:28 -0500
committerGitHub <noreply@github.com>2017-12-06 16:38:28 -0500
commit192a8c1386ada33cb797d1e7a56c38bf2d21e338 (patch)
treefbf36b98d05687a16294276f0e3b6e9ce7bdb6d3 /roles/openshift_loadbalancer
parent4326fb78c0e16e848c946d509ba9de7247ae0562 (diff)
parent966e031276e4bcda17f96ebd93d94789a4befd73 (diff)
downloadopenshift-192a8c1386ada33cb797d1e7a56c38bf2d21e338.tar.gz
openshift-192a8c1386ada33cb797d1e7a56c38bf2d21e338.tar.bz2
openshift-192a8c1386ada33cb797d1e7a56c38bf2d21e338.tar.xz
openshift-192a8c1386ada33cb797d1e7a56c38bf2d21e338.zip
Merge pull request #6034 from cwilkers/containerized-lb-portfix
Mod startup script to publish all frontend binds
Diffstat (limited to 'roles/openshift_loadbalancer')
-rw-r--r--roles/openshift_loadbalancer/templates/haproxy.docker.service.j22
1 files changed, 1 insertions, 1 deletions
diff --git a/roles/openshift_loadbalancer/templates/haproxy.docker.service.j2 b/roles/openshift_loadbalancer/templates/haproxy.docker.service.j2
index 57121447d..0343a7eb0 100644
--- a/roles/openshift_loadbalancer/templates/haproxy.docker.service.j2
+++ b/roles/openshift_loadbalancer/templates/haproxy.docker.service.j2
@@ -5,7 +5,7 @@ PartOf={{ openshift_docker_service_name }}.service
[Service]
ExecStartPre=-/usr/bin/docker rm -f openshift_loadbalancer
-ExecStart=/usr/bin/docker run --rm --name openshift_loadbalancer -p {{ openshift_master_api_port | default(8443) }}:{{ openshift_master_api_port | default(8443) }} -v /etc/haproxy/haproxy.cfg:/etc/haproxy/haproxy.cfg:ro --entrypoint=haproxy {{ openshift.common.router_image }}:{{ openshift_image_tag }} -f /etc/haproxy/haproxy.cfg
+ExecStart=/usr/bin/docker run --rm --name openshift_loadbalancer {% for frontend in openshift_loadbalancer_frontends %} {% for bind in frontend.binds %} -p {{ bind |regex_replace('^[^:]*:(\d+).*$', '\\1') }}:{{ bind |regex_replace('^[^:]*:(\d+).*$', '\\1') }} {% endfor %} {% endfor %} -v /etc/haproxy/haproxy.cfg:/etc/haproxy/haproxy.cfg:ro --entrypoint=haproxy {{ openshift.common.router_image }}:{{ openshift_image_tag }} -f /etc/haproxy/haproxy.cfg
ExecStartPost=/usr/bin/sleep 10
ExecStop=/usr/bin/docker stop openshift_loadbalancer
LimitNOFILE={{ openshift_loadbalancer_limit_nofile | default(100000) }}