Docker build for azure-cli image fails on x86 #30126
Labels
Azure CLI Team
The command of the issue is owned by Azure CLI team
customer-reported
Issues that are reported by GitHub users external to the Azure organization.
question
The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Similar-Issue
Milestone
Describe the bug
Hi team
we are trying to build this docker file
https://github.com.mcas.ms/Azure/azure-cli/blob/azure-cli-2.65.0/scripts/release/debian/Dockerfile
but we are facing issues during build. We did below changes but still it gives errors.
dpkg-shlibdeps: error: cannot read debian/azure-cli/opt/az/lib/python3./lib-dynload/_ssl.cpython-3-*-linux-gnu.so: No such file or directory
make[1]: Leaving directory '/azure-cli'
make[1]: *** [debian/rules:21: override_dh_install] Error 2
make: *** [debian/rules:8: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
fyi we could locate same file at below 3 locations:
RUN find / -name "_ssl.cpython-3*-*-linux-gnu.so" 14.0s
=> => # /usr/lib/python3.10/lib-dynload/_ssl.cpython-310-x86_64-linux-gnu.so
=> => # /azure-cli/python_env/lib/python3.10/lib-dynload/_ssl.cpython-310-x86_64-linux-gnu.so
=> => # /azure-cli/build/lib.linux-x86_64-3.10/_ssl.cpython-310-x86_64-linux-gnu.so
Command to copy file: RUN mkdir -p debian/azure-cli/opt/az/lib/python3./lib-dynload/
RUN cp /usr/lib/python3.10/lib-dynload/_ssl.cpython-310-x86_64-linux-gnu.so debian/azure-cli/opt/az/lib/python3./lib- dynload/
please let us know what can be done here
Related command
Command used to build docker image.
docker build --target build-env -f ./scripts/release/debian/Dockerfile -t azure/azure-cli:ubuntu-builder .
Errors
Error:
dpkg-shlibdeps: error: cannot read debian/azure-cli/opt/az/lib/python3./lib-dynload/_ssl.cpython-3--linux-gnu.so: No such file or directory
. dpkg-shlibdeps: debug: Using symbols file /var/lib/dpkg/info/libc6:amd64.symbols for libm.so.6
. dpkg-shlibdeps: debug: Using symbols file /var/lib/dpkg/info/libc6:amd64.symbols for libc.so.6
. dpkg-shlibdeps: debug: >> Scanning debian/azure-cli/opt/az/lib/python3./lib-dynload/_ssl.cpython-3*-*-linux-gnu.so (for Depends field)
. make[1]: *** [debian/rules:21: override_dh_install] Error 2
. make[1]: Leaving directory '/azure-cli'
. make: *** [debian/rules:8: binary] Error 2
. dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
Issue script & Debug output
As mentioned above
Expected behavior
Image should build successfully
https://github.com.mcas.ms/Azure/azure-cli/blob/azure-cli-2.65.0/scripts/release/debian/Dockerfile
Environment Summary
OS: ubuntu 22.04
Additional context
No response
The text was updated successfully, but these errors were encountered: