Merge "repair rally dockerfile"
This commit is contained in:
commit
7168f3c430
@ -17,12 +17,16 @@ RUN useradd --user-group rally
|
||||
|
||||
ADD rally-archive /rally-source
|
||||
RUN ln -s rally-source/* rally \
|
||||
&& useradd --user-group rally \
|
||||
&& /var/lib/kolla/venv/bin/pip --no-cache-dir install --upgrade -c requirements/upper-constraints.txt /rally \
|
||||
&& mkdir -p /etc/rally /var/log/rally \
|
||||
&& useradd --user-group rally
|
||||
&& mkdir -p /etc/rally /var/log/rally /home/rally \
|
||||
&& chown -R rally: /etc/rally /var/log/rally /home/rally
|
||||
|
||||
{% endif %}
|
||||
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
RUN chmod 755 /usr/local/bin/kolla_extend_start
|
||||
|
||||
RUN usermod -a -G kolla rally
|
||||
|
||||
{% block rally_footer %}{% endblock %}
|
||||
|
15
docker/rally/extend_start.sh
Normal file
15
docker/rally/extend_start.sh
Normal file
@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Bootstrap and exit if KOLLA_BOOTSTRAP variable is set. This catches all cases
|
||||
# of the KOLLA_BOOTSTRAP variable being set, including empty.
|
||||
if [[ "${!KOLLA_BOOTSTRAP[@]}" ]]; then
|
||||
rally-manage db recreate
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [[ ! -d "/var/log/kolla/rally" ]]; then
|
||||
mkdir -p /var/log/kolla/rally
|
||||
fi
|
||||
if [[ $(stat -c %a /var/log/kolla/rally) != "755" ]]; then
|
||||
chmod 755 /var/log/kolla/rally
|
||||
fi
|
Loading…
Reference in New Issue
Block a user