Customizations for Swift
This patchset contains customization of Dockerfile of Swift containers. Change-Id: I69250c4d9f6cc3949c9b9b52ea4b0cc2aec0231e Partially-implements: blueprint third-party-plugin-support
This commit is contained in:
parent
e4259f805b
commit
503120657e
@ -1,22 +1,21 @@
|
||||
FROM {{ namespace }}/{{ image_prefix }}swift-base:{{ tag }}
|
||||
MAINTAINER {{ maintainer }}
|
||||
|
||||
{% import "macros.j2" as macros with context %}
|
||||
|
||||
{% if install_type == 'binary' %}
|
||||
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
||||
|
||||
RUN yum -y install \
|
||||
openstack-swift-account \
|
||||
&& yum clean all
|
||||
|
||||
{% set swift_acount_packages = ['openstack-swift-account'] %}
|
||||
{% elif base_distro in ['ubuntu'] %}
|
||||
|
||||
RUN apt-get -y install --no-install-recommends \
|
||||
swift-account \
|
||||
&& apt-get clean
|
||||
|
||||
{% set swift_acount_packages = ['swift-account'] %}
|
||||
{% endif %}
|
||||
|
||||
RUN {{ macros.install_packages(swift_acount_packages | customizable("packages")) }}
|
||||
|
||||
{% endif %}
|
||||
|
||||
{% block swift_account_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
{{ include_footer }}
|
||||
|
||||
USER swift
|
||||
|
@ -1,35 +1,25 @@
|
||||
FROM {{ namespace }}/{{ image_prefix }}openstack-base:{{ tag }}
|
||||
MAINTAINER {{ maintainer }}
|
||||
|
||||
{% import "macros.j2" as macros with context %}
|
||||
|
||||
{% if install_type == 'binary' %}
|
||||
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
||||
|
||||
RUN yum -y install \
|
||||
openstack-swift \
|
||||
&& yum clean all
|
||||
|
||||
{% set swift_base_packages = ['openstack-swift'] %}
|
||||
{% elif base_distro in ['ubuntu'] %}
|
||||
|
||||
RUN apt-get -y install --no-install-recommends \
|
||||
swift \
|
||||
&& apt-get clean
|
||||
|
||||
{% set swift_base_packages = ['swift'] %}
|
||||
{% endif %}
|
||||
|
||||
RUN {{ macros.install_packages(swift_base_packages | customizable("packages")) }}
|
||||
|
||||
{% elif install_type == 'source' %}
|
||||
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
||||
|
||||
RUN yum -y install \
|
||||
liberasurecode-devel \
|
||||
&& yum clean all
|
||||
|
||||
{% set swift_base_packages = ['liberasurecode-devel'] %}
|
||||
{% elif base_distro in ['ubuntu', 'debian'] %}
|
||||
|
||||
RUN apt-get -y install --no-install-recommends \
|
||||
liberasurecode-dev \
|
||||
&& apt-get clean
|
||||
|
||||
{% set swift_base_packages = ['liberasurecode-dev'] %}
|
||||
{% endif %}
|
||||
|
||||
RUN {{ macros.install_packages(swift_base_packages | customizable("packages")) }}
|
||||
ADD swift-base-archive /swift-base-source
|
||||
RUN ln -s swift-base-source/* swift \
|
||||
&& useradd --user-group swift \
|
||||
@ -56,3 +46,6 @@ COPY build-swift-ring.py /usr/local/bin/kolla_build_swift_ring
|
||||
RUN mkdir -p /opt/swift
|
||||
|
||||
RUN usermod -a -G kolla swift
|
||||
|
||||
{% block swift_base_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
|
@ -1,22 +1,21 @@
|
||||
FROM {{ namespace }}/{{ image_prefix }}swift-base:{{ tag }}
|
||||
MAINTAINER {{ maintainer }}
|
||||
|
||||
{% import "macros.j2" as macros with context %}
|
||||
|
||||
{% if install_type == 'binary' %}
|
||||
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
||||
|
||||
RUN yum -y install \
|
||||
openstack-swift-container \
|
||||
&& yum clean all
|
||||
|
||||
{% set swift_container_packages = ['openstack-swift-container'] %}
|
||||
{% elif base_distro in ['ubuntu'] %}
|
||||
|
||||
RUN apt-get -y install --no-install-recommends \
|
||||
swift-container \
|
||||
&& apt-get clean
|
||||
|
||||
{% set swift_container_packages = ['swift-container'] %}
|
||||
{% endif %}
|
||||
|
||||
RUN {{ macros.install_packages(swift_container_packages | customizable("packages")) }}
|
||||
|
||||
{% endif %}
|
||||
|
||||
{% block swift_container_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
{{ include_footer }}
|
||||
|
||||
USER swift
|
||||
|
@ -1,22 +1,21 @@
|
||||
FROM {{ namespace }}/{{ image_prefix }}swift-base:{{ tag }}
|
||||
MAINTAINER {{ maintainer }}
|
||||
|
||||
{% import "macros.j2" as macros with context %}
|
||||
|
||||
{% if install_type == 'binary' %}
|
||||
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
||||
|
||||
RUN yum -y install \
|
||||
openstack-swift-object \
|
||||
&& yum clean all
|
||||
|
||||
{% set swift_object_packages = ['openstack-swift-object'] %}
|
||||
{% elif base_distro in ['ubuntu'] %}
|
||||
|
||||
RUN apt-get -y install --no-install-recommends \
|
||||
swift-object \
|
||||
&& apt-get clean
|
||||
|
||||
{% set swift_object_packages = ['swift-object'] %}
|
||||
{% endif %}
|
||||
|
||||
RUN {{ macros.install_packages(swift_object_packages | customizable("packages")) }}
|
||||
|
||||
{% endif %}
|
||||
|
||||
{% block swift_object_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
{{ include_footer }}
|
||||
|
||||
USER swift
|
||||
|
@ -1,22 +1,21 @@
|
||||
FROM {{ namespace }}/{{ image_prefix }}swift-base:{{ tag }}
|
||||
MAINTAINER {{ maintainer }}
|
||||
|
||||
{% import "macros.j2" as macros with context %}
|
||||
|
||||
{% if install_type == 'binary' %}
|
||||
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
||||
|
||||
RUN yum -y install \
|
||||
openstack-swift-proxy \
|
||||
&& yum clean all
|
||||
|
||||
{% set swift_proxy_server_packages = ['openstack-swift-proxy'] %}
|
||||
{% elif base_distro in ['ubuntu'] %}
|
||||
|
||||
RUN apt-get -y install --no-install-recommends \
|
||||
swift-proxy \
|
||||
&& apt-get clean
|
||||
|
||||
{% set swift_proxy_server_packages = ['swift-proxy'] %}
|
||||
{% endif %}
|
||||
|
||||
RUN {{ macros.install_packages(swift_proxy_server_packages | customizable("packages")) }}
|
||||
|
||||
{% endif %}
|
||||
|
||||
{% block swift_proxy_server_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
{{ include_footer }}
|
||||
|
||||
USER swift
|
||||
|
@ -1,23 +1,20 @@
|
||||
FROM {{ namespace }}/{{ image_prefix }}swift-base:{{ tag }}
|
||||
MAINTAINER {{ maintainer }}
|
||||
|
||||
{% import "macros.j2" as macros with context %}
|
||||
|
||||
{% if base_distro in ['fedora', 'centos', 'oraclelinux', 'rhel'] %}
|
||||
|
||||
RUN yum -y install \
|
||||
rsync \
|
||||
&& yum clean all
|
||||
|
||||
{% set swift_rsyncd_packages = ['rsync'] %}
|
||||
{% elif base_distro in ['ubuntu', 'debian'] %}
|
||||
|
||||
RUN apt-get -y install --no-install-recommends \
|
||||
rsync \
|
||||
&& apt-get clean
|
||||
|
||||
{% set swift_rsyncd_packages = ['rsync'] %}
|
||||
{% endif %}
|
||||
|
||||
RUN {{ macros.install_packages(swift_rsyncd_packages | customizable("packages")) }}
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
RUN chmod 755 /usr/local/bin/kolla_extend_start
|
||||
|
||||
{% block swift_rsyncd_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
{{ include_footer }}
|
||||
|
||||
USER swift
|
||||
|
Loading…
Reference in New Issue
Block a user