Pipeline for building custom OpenStack Kolla container images.
Prepare environment:
# create venv
python3 -m venv venv
# activate venv
source venv/bin/activate
# install requirements
pip install -r requirements.txt
# install kolla
pip install git+https://opendev.org/openstack/kolla@stable/2024.1
Build images:
kolla-build --config-file kolla-build.conf --profile custom
Go to Actions and click on Run workflow
.
Images are pushed to quay.io/nimbolus.
- Add patch file to
patches/<image-name>/<patch-name>.patch
. - Add patch file name to
patches/<image-name>/series
file. - Create additions archive in kolla-build.conf:
[<image-name>-additions-patches]
type = local
location = patches/<image-name>/
- Install
patch
binary and apply the patches in template_overrides.j2:
{% set <image-name>_packages_append = ['patch'] %}
{% block <image-name>_footer %}
ADD additions-archive /
RUN bash -c 'while read patch; do patch -d /var/lib/kolla/venv/lib/python3.9/site-packages -p 1 -i /additions/$patch; done < /additions/series'
{% endblock %}