First update on image customization

Following the openstack transition to Debian, this aims to start the
creation of the debian docker image files, adapting the customization
to proper enable WSGI on Debian.

Since we are not currently building Openstack on debian yet, this
won't have any effect on our current build/testing.

Also, since these images use apache, there's a change which is yet to
be done on the stx-openstack-helm manifest to user the "www-data"
socket-user insetad of "apache", since the latter one is for centos
only.

Test Plan:

PASS: Build horizon and placement images using a debian base image
PASS: Override both images on a working Openstack application
PASS: Access the horizon interface
PASS: Remove and apply Openstack

Story: 2010072
Task: 45558

Signed-off-by: Pedro Almeida <pedro.monteiroazevedodemouraalmeida@windriver.com>
Change-Id: I776e03b863056fbb068e2eca0637e9c8b64b4b0c
This commit is contained in:
Pedro Almeida 2022-06-07 16:59:17 -03:00
parent 1b989b481a
commit c040bd5a76
4 changed files with 50 additions and 0 deletions

View File

@ -0,0 +1,14 @@
BUILDER=loci
LABEL=stx-horizon
PROJECT=horizon
PROJECT_REPO=https://opendev.org/openstack/horizon.git
PIP_PACKAGES="pycryptodomex python-ceilometerclient \
coverage pyudev ldap"
PROFILES="fluent horizon apache"
CUSTOMIZATION="\
ln -s /etc/apache2/mods-available/wsgi.load /etc/apache2/mods-enabled/wsgi.load && \
ln -s /etc/apache2/mods-available/wsgi.conf /etc/apache2/mods-enabled/wsgi.conf && \
ln -s /bin/true /usr/bin/a2enmod && \
sed -i -e 's/raise ImproperlyConfigured..mysqlclient 1.3.13 or newer is required.*/pass/' /var/lib/openstack/lib/python3.9/site-packages/django/db/backends/mysql/base.py && \
sed -i -e '/query.decode.errors=.replace../s/decode/encode/' /var/lib/openstack/lib/python3.9/site-packages/django/db/backends/mysql/operations.py
"

View File

@ -0,0 +1,15 @@
BUILDER=loci
LABEL=stx-horizon
PROJECT=horizon
PROJECT_REPO=https://opendev.org/openstack/horizon.git
PROJECT_REF=stable/ussuri
PIP_PACKAGES="pycryptodomex python-ceilometerclient \
coverage pyudev ldap"
PROFILES="fluent horizon apache"
CUSTOMIZATION="\
ln -s /etc/apache2/mods-available/wsgi.load /etc/apache2/mods-enabled/wsgi.load && \
ln -s /etc/apache2/mods-available/wsgi.conf /etc/apache2/mods-enabled/wsgi.conf && \
ln -s /bin/true /usr/bin/a2enmod && \
sed -i -e 's/raise ImproperlyConfigured..mysqlclient 1.3.13 or newer is required.*/pass/' /var/lib/openstack/lib/python3.9/site-packages/django/db/backends/mysql/base.py && \
sed -i -e '/query.decode.errors=.replace../s/decode/encode/' /var/lib/openstack/lib/python3.9/site-packages/django/db/backends/mysql/operations.py
"

View File

@ -0,0 +1,10 @@
BUILDER=loci
LABEL=stx-placement
PROJECT=placement
PROJECT_REPO=https://opendev.org/openstack/placement.git
PIP_PACKAGES="pycryptodomex httplib2"
PROFILES="apache"
CUSTOMIZATION="\
ln -s /etc/apache2/mods-available/wsgi.load /etc/apache2/mods-enabled/wsgi.load && \
ln -s /etc/apache2/mods-available/wsgi.conf /etc/apache2/mods-enabled/wsgi.conf
"

View File

@ -0,0 +1,11 @@
BUILDER=loci
LABEL=stx-placement
PROJECT=placement
PROJECT_REPO=https://opendev.org/openstack/placement.git
PROJECT_REF=stable/ussuri
PIP_PACKAGES="pycryptodomex httplib2"
PROFILES="apache"
CUSTOMIZATION="\
ln -s /etc/apache2/mods-available/wsgi.load /etc/apache2/mods-enabled/wsgi.load && \
ln -s /etc/apache2/mods-available/wsgi.conf /etc/apache2/mods-enabled/wsgi.conf
"