From e38ce02114966350aa3cbebb68b93d3b1110d9b1 Mon Sep 17 00:00:00 2001 From: Riccardo Pittau Date: Wed, 17 Nov 2021 17:41:25 +0100 Subject: [PATCH] Follow-up to build image from source --- ironic-rpm-list.txt | 1 + ironic-source-list.txt | 1 + prepare-image.sh | 10 +++++++--- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ironic-rpm-list.txt b/ironic-rpm-list.txt index 3e8078b4e..b69f9cbb0 100644 --- a/ironic-rpm-list.txt +++ b/ironic-rpm-list.txt @@ -3,6 +3,7 @@ openstack-ironic-api openstack-ironic-conductor openstack-ironic-inspector python3-dracclient +python3-gunicorn python3-ibmcclient python3-ironic-prometheus-exporter python3-proliantutils diff --git a/ironic-source-list.txt b/ironic-source-list.txt index 3f85999e6..17d40dfb1 100644 --- a/ironic-source-list.txt +++ b/ironic-source-list.txt @@ -1,4 +1,5 @@ crudini +gunicorn ironic @ git+https://opendev.org/openstack/ironic ironic-inspector @ git+https://opendev.org/openstack/ironic-inspector ironic-prometheus-exporter diff --git a/prepare-image.sh b/prepare-image.sh index bea561ab9..4668713ec 100755 --- a/prepare-image.sh +++ b/prepare-image.sh @@ -20,9 +20,10 @@ fi # SOURCE install # if [[ $INSTALL_TYPE == "source" ]]; then + BUILD_DEPS="python3-pip python3-devel gcc git-core" dnf upgrade -y - dnf install -y python3-pip python3-devel gcc git-core - pip3 install --upgrade pip + dnf install -y $BUILD_DEPS + pip3 install pip==21.3.1 pip3 install --prefix /usr -r $IRONIC_PKG_LIST -c https://raw.githubusercontent.com/openstack/requirements/master/upper-constraints.txt # ironic and ironic-inspector system configuration @@ -31,6 +32,9 @@ if [[ $INSTALL_TYPE == "source" ]]; then getent passwd ironic >/dev/null || useradd -r -g ironic -s /sbin/nologin ironic -d /var/lib/ironic getent group ironic-inspector >/dev/null || groupadd -r ironic-inspector getent passwd ironic-inspector >/dev/null || useradd -r -g ironic-inspector -s /sbin/nologin ironic-inspector -d /var/lib/ironic-inspector + + # clean installed build dependencies + dnf remove -y $BUILD_DEPS fi xargs -rtd'\n' dnf install -y < /tmp/${PKGS_LIST} @@ -41,7 +45,7 @@ if [[ ! -z ${EXTRA_PKGS_LIST:-} ]]; then fi fi -dnf install -y --enablerepo=epel inotify-tools python3-gunicorn +dnf install -y --enablerepo=epel inotify-tools dnf clean all rm -rf /var/cache/{yum,dnf}/*