Customizations for haproxy

This patchset contains customization of Dockerfile of haproxy
containers

Change-Id: I67790816766641ebc3138d6b3726f0bbd9c68038
Partially-implements: blueprint third-party-plugin-support
Signed-off-by: Eduardo Gonzalez <dabarren@gmail.com>
This commit is contained in:
Eduardo Gonzalez 2016-07-28 15:30:41 +01:00
parent c895034030
commit 3eb82949c2

View File

@ -1,19 +1,10 @@
FROM {{ namespace }}/{{ image_prefix }}base:{{ tag }}
MAINTAINER {{ maintainer }}
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
{% import "macros.j2" as macros with context %}
RUN yum -y install \
haproxy \
&& yum clean all
{% elif base_distro in ['debian', 'ubuntu'] %}
RUN apt-get -y install --no-install-recommends \
haproxy \
&& apt-get clean
{% endif %}
{% set haproxy_packages = ['haproxy'] %}
RUN {{ macros.install_packages(haproxy_packages | customizable("packages")) }}
RUN usermod -a -G kolla haproxy \
&& mkdir -p /var/lib/kolla/haproxy \
@ -22,4 +13,6 @@ RUN usermod -a -G kolla haproxy \
COPY ensure_latest_config.sh /usr/local/bin/kolla_ensure_haproxy_latest_config
RUN chmod 755 /usr/local/bin/kolla_ensure_haproxy_latest_config
{% block haproxy_footer %}{% endblock %}
{% block footer %}{% endblock %}
{{ include_footer }}