stx-keystone-api-proxy: centos: docker image build fails

Bug #1997977 reported by Davlet Panech
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
High
Alyson Deives Pereira

Bug Description

Brief Description
-----------------
stx-keystone-api-proxy fails to compile on CentOS:

http://mirror.starlingx.cengn.ca/mirror/starlingx/master/centos/containers/20221125T032358Z/logs/jenkins-STX_build_docker_flock_images-632.log.html

ERROR: Could not find a version that satisfies the requirement zerorpc (from sysinv===1.0->-c /tmp/wheels/upper-constraints.txt (line 728)) (from versions: none)
ERROR: No matching distribution found for zerorpc (from sysinv===1.0->-c /tmp/wheels/upper-constraints.txt (line 728))

Severity
--------
Major

Steps to Reproduce
------------------
Try building docker images

Expected Behavior
------------------
Build succeeds

Actual Behavior
----------------
Build fails

Reproducibility
---------------
Seen once

System Configuration
--------------------
N/A

Branch/Pull Time/Commit
-----------------------
master/2022-11-25

Last Pass
---------
master/2022-11-24

Timestamp/Logs
--------------
Building stx-keystone-api-proxy
Python2 service stx-keystone-api-proxy
Downloading http://mirror.starlingx.cengn.ca:80//mirror/starlingx/master/centos/containers/20221125T032358Z/outputs/wheels/stx-centos-stable-wheels-py2.tar => /localdisk/loadbuild/jenkins/master-containers/20221125T032358Z/std/build-images/loci/stx-wheels/stx-centos-stable-wheels-py2.tar
[...]
Step 35/35 : RUN /opt/loci/stx-scripts/install.sh
---> Running in b39cc360b701
+ LOCI_DIR=/opt/loci
+ /opt/loci/stx-scripts/setup-package-repos.sh
+ [[ -n '' ]]
+ /opt/loci/scripts/install.sh
[...]
Downloading lxml-4.4.1-cp27-cp27mu-manylinux1_x86_64.whl (5.7 MB)
Processing /tmp/wheels/psutil-5.6.3-cp27-cp27mu-linux_x86_64.whl
Collecting ruamel.yaml>=0.13.14
Downloading ruamel.yaml-0.16.13-py2.py3-none-any.whl (111 kB)
Collecting docker===4.0.2
Downloading docker-4.0.2-py2.py3-none-any.whl (138 kB)
ERROR: Could not find a version that satisfies the requirement zerorpc (from sysinv===1.0->-c /tmp/wheels/upper-constraints.txt (line 728)) (from versions: none)
ERROR: No matching distribution found for zerorpc (from sysinv===1.0->-c /tmp/wheels/upper-constraints.txt (line 728))
The command '/bin/sh -c /opt/loci/stx-scripts/install.sh' returned a non-zero code: 1
Command (docker) failed, attempt 1 of 5.

Test Activity
-------------
Other

Workaround
----------
N/A

Revision history for this message
Davlet Panech (dpanech) wrote :
Revision history for this message
Davlet Panech (dpanech) wrote :

Al Bailey says:
---------------

The build-docker-images failure for stx-keystone-api-proxy is because it could not find zerorpc.

ERROR: Could not find a version that satisfies the requirement zerorpc (from sysinv===1.0->-c /tmp/wheels/upper-constraints.txt (line 728)) (from versions: none)
ERROR: No matching distribution found for zerorpc (from sysinv===1.0->-c /tmp/wheels/upper-constraints.txt (line 728))
The command '/bin/sh -c /opt/loci/stx-scripts/install.sh' returned a non-zero code: 1
Command (docker) failed, attempt 5 of 5.
Max command attempts reached. Aborting...
Failed to build stx-keystone-api-proxy... Aborting

So we need to add that to the wheel

Revision history for this message
Al Bailey (albailey1974) wrote :

I think the fix is to create
stx/integ/debian_stable_wheels.inc

and add:
zerorpc-python-wheel

Revision history for this message
Davlet Panech (dpanech) wrote :

> I think the fix is to create
> stx/integ/debian_stable_wheels.inc

This bug is about a CentOS build. Its not clear whether this affects Debian.

Revision history for this message
Davlet Panech (dpanech) wrote :

zerorpc was recently added to sysinv: https://review.opendev.org/c/starlingx/config/+/859571

Revision history for this message
Al Bailey (albailey1974) wrote :

It may be possible to build the centos images by changing the requirements.txt to be
zerorpc;python_version>="3.0"

However, this will only work if the sysinv components being imported in the centos image are not importing a file that imports zerorpc

Ghada Khalil (gkhalil)
tags: added: stx.build
Revision history for this message
Al Bailey (albailey1974) wrote :

Looks like this line
https://github.com/starlingx/distcloud/blob/master/distributedcloud/centos/stx-keystone-api-proxy.stable_docker_image#L14

is pulling in sysinv, but that line does not exist for the debian image.
The simple fix might be to remove that line

Revision history for this message
Al Bailey (albailey1974) wrote :

One thing to note.
Centos images pull in Centos version of cgcs-patch which contains sysinv imports.
Debian images pull in Debian version of sw-patch which does not contain sysinv imports

The fix might just be to add the default zerorpc wheel to
cgcs-root/build-tools/build-wheels/centos/stable-wheels-py2.cfg

The code for sysinv may still import zerorpc, but the image will not run sysinv or zerorpc, so the fix should be sufficient to get the image to build

Changed in starlingx:
assignee: nobody → Alyson Deives Pereira (adeivesp)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to root (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/starlingx/root/+/866065

Changed in starlingx:
status: New → In Progress
Ghada Khalil (gkhalil)
Changed in starlingx:
importance: Undecided → High
tags: added: stx.8.0
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to root (master)

Reviewed: https://review.opendev.org/c/starlingx/root/+/866065
Committed: https://opendev.org/starlingx/root/commit/806e3de5e38da5e10bb6333b8228a71b16acd391
Submitter: "Zuul (22348)"
Branch: master

commit 806e3de5e38da5e10bb6333b8228a71b16acd391
Author: Alyson Deives Pereira <email address hidden>
Date: Tue Nov 29 17:22:23 2022 -0300

    Add zerorpc wheel package

    Build of docker image stx-keystone-api-proxy fails on CentOS, since
    the docker image includes sysinv, which requires zerorpc.

    The code for sysinv may still import zerorpc, but the image will not
    run sysinv or zerorpc, so this fix is sufficient to get the image to
    build.

    TEST PLAN:
    PASS: Build stx-keystone-api-proxy docker image on CentOS

    Closes-Bug: 1997977

    Signed-off-by: Alyson Deives Pereira <email address hidden>
    Change-Id: I30da6ec139f4cd31759eb249f008e1101e02e713

Changed in starlingx:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.