
Current Swift playbook is based on the preassumption of AIO setup. However, if one goes with default multinode setup (ansible/inventory/multinode), it follows the P + ACO deployment model, which proxy-server runs on controller nodes where ACO (account/container/object services) run on storage nodes. It will break because swift proxy-server no longer has access (it shouldn't have) to /srv/node path. This change ensure disk mounting part only happens on storage node. It also moves chown from proxy-server Dockerfile to rsyncd because no matter with PACO, P+ACO or P+A+C+O model, rsyncd is always running on each storage node. Change-Id: I3aa20454902caa9c84d3901bb91e4e4c93ac5f34 Partially-Implements: blueprint swift-physical-disk Closes-Bug: #1537544
38 lines
1.1 KiB
Django/Jinja
38 lines
1.1 KiB
Django/Jinja
FROM {{ namespace }}/{{ image_prefix }}openstack-base:{{ tag }}
|
|
MAINTAINER {{ maintainer }}
|
|
|
|
{% if install_type == 'binary' %}
|
|
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
|
|
|
RUN yum -y install openstack-swift \
|
|
&& yum clean all
|
|
|
|
{% endif %}
|
|
{% elif install_type == 'source' %}
|
|
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
|
|
|
|
RUN yum -y install \
|
|
liberasurecode-devel \
|
|
&& yum clean all
|
|
|
|
{% elif base_distro in ['ubuntu'] %}
|
|
|
|
RUN apt-get install -y --no-install-recommends \
|
|
liberasurecode-dev \
|
|
&& apt-get clean
|
|
|
|
{% endif %}
|
|
|
|
ADD swift-base-archive /swift-base-source
|
|
RUN ln -s swift-base-source/* swift \
|
|
&& useradd --user-group swift \
|
|
&& /var/lib/kolla/venv/bin/pip --no-cache-dir install --upgrade -c requirements/upper-constraints.txt /swift \
|
|
&& mkdir -p /etc/swift /var/log/swift /home/swift \
|
|
&& cp -r /swift/etc/* /etc/swift/ \
|
|
&& chown -R swift: /etc/swift /var/log/swift /home/swift
|
|
|
|
{% endif %}
|
|
|
|
COPY build-swift-ring.py /usr/local/bin/kolla_build_swift_ring
|
|
RUN mkdir /opt/swift
|