Why I did it This fix is to address issue: Azure/sonic-mgmt#5280 In the sonic-mgmt Dockerfile, python package allure-pytest is installed after ENV USER $user. Consequently the package is installed to path /home/$user/.local and is only available to the $user account. If we use root account in sonic-mgmt docker container to run tests, any script importing the allure package will fail with ImportError. We need to install the allure-pytest package to global directory instead of user local directory. How I did it Update the sonic-mgmt Dockerfile to ensure that the allure-pytest package is installed to global directory How to verify it Build a new sonic-mgmt docker image based on the changes. Use sonic-mgmt docker container of the newly built image to run test scripts that depend on the allure-pytest package. No ImportError is raised. |
||
---|---|---|
.. | ||
Dockerfile.j2 | ||
sonic-jenkins.pub |