Skip to content

haproxy reload command does not reload config #31

@skjbulcher

Description

@skjbulcher

Running an unaltered haproxy 1.6.9 image. The config is set up to proxy requests on port 80 to various other ports on the host (I use haproxy as an http proxy for docker-served webhosts).

docker-compose.yml

haproxy:
    image: haproxy:1.6.9
    ports:
      - "80:80"
    volumes:
      - ./config/haproxy.cfg:/usr/local/etc/haproxy/haproxy.cfg

According to the documentation, I should be able to reload changes to haproxy.cfg by running the command docker kill -s HUP <my-running-haproxy>.

Actions taken

  1. Edit haproxy.cfg; add forwarding for a new host, e.g. newhost
  2. docker kill -s HUP proxy_haproxy_1

Result

  1. docker-compose logs displays:

    haproxy_1           | <5>haproxy-systemd-wrapper: re-executing on SIGHUP.
    haproxy_1           | <7>haproxy-systemd-wrapper: executing /usr/local/sbin/haproxy -p /run/haproxy.pid -f /usr/local/etc/haproxy/haproxy.cfg -Ds -sf 7
    
  2. Visiting http://newhost in a browser results in a 503 Service Unavailable error

  3. Issue docker-compose restart

  4. Visiting http://newhost now works

Expected Result

  1. Visiting http://newhost works immediately following the execution of docker kill -s HUP proxy_haproxy_1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions