0

In Singularity when building under fake-root anything Ubuntu based with in %post either apt update -y or apt install -y openssh-client or their apt-get versions or with -f in the definition file fails fatally with

groupadd: failure while writing changes to /etc/group addgroup: `/sbin/groupadd -g 101 ssh' returned error code 10. Exiting. Errors were encountered while processing: openssh-client E: Sub-process /usr/bin/dpkg returned an error code (1) FATAL: While performing build: while running engine: exit status 100 

I see why adding a user is an issue, but yum update works fine in Rocky 9 (I cannot switch to it due to some requirements). This is on a cluster where I do NOT have root priviledges and have to use Singularity and docker isn't available —the base OS is CentOS 7 and glibc issues are insurmountable. I have tried a bunch of different Ubuntu images, ranging from Nvidia's Docker Ubuntu image and officially signed to unsigned Singularity images.

Conda can install ssh, but the issue is apt update fails and I cannot work around it.

I feel like I missing something obvious based on the lack of much on this online...

1 Answer 1

0

The solution is spoofing the package manager via equivs

apt-get install -y equivs # Manual `equivs-control openssh-client` echo 'Section: misc' > openssh-client echo 'Priority: optional' > openssh-client echo 'Standards-Version: 3.9.2' > openssh-client echo 'Package: openssh-client' > openssh-client echo 'Version: 1:8.9p1-3ubuntu0.4' > openssh-client echo 'Maintainer: Your Name <[email protected]>' > openssh-client echo 'Provides: openssh-client' > openssh-client echo 'Architecture: amd64' > openssh-client echo 'Description: fake package' > openssh-client equivs-build openssh-client dpkg -i equivs-dummy_1.0_all.deb 

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.