docker-library / haproxy

Docker Official Image packaging for HAProxy
http://www.haproxy.org/
GNU General Public License v2.0
351 stars 161 forks source link

Why build from source code? #204

Closed pyy closed 1 year ago

pyy commented 1 year ago

May I ask why do we build the haproxy from source code, not directly use distro's package? Thank you.

tianon commented 1 year ago

For images we maintain on behalf of other projects, we try to follow their recommendations in the way we install and configure their software. In the case of HAProxy, I'm not aware of any distribution packages available that are published for every supported version and are actively recommended by the project -- their instructions at http://docs.haproxy.org/2.7/intro.html#3.7 talk specifically about the source code if you want the latest or a particular version.

Additionally, anyone wanting to use a particular distribution's packages of HAProxy can do so pretty trivially without any support from us:

FROM debian:bullseye
RUN apt-get update && apt-get install -y haproxy
tianon commented 1 year ago

See also https://github.com/docker-library/faq#why-do-so-many-official-images-build-from-source