Can't enter toolbox image because passwd is not installed
Following the instructions from: https://gitlab.com/BuildStream/buildstream-docker-images/-/blob/master/USING.md
On Fedora 38 with toolbox version 0.0.99.4
toolbox create -i docker.io/buildstream/buildstream:dev
toolbox enter buildstream-dev
The enter command fails as follows:
$ toolbox enter buildstream-dev
Error: failed to initialize container buildstream-dev
With debug:
$ toolbox enter -v buildstream-dev
DEBU Running as real user ID 1000
DEBU Resolved absolute path to the executable as /usr/bin/toolbox
DEBU Running on a cgroups v2 host
DEBU Looking for sub-GID and sub-UID ranges for user dsd
DEBU TOOLBOX_PATH is /usr/bin/toolbox
DEBU Migrating to newer Podman
DEBU Toolbox config directory is /home/dsd/.config/toolbox
DEBU Current Podman version is 4.5.0
DEBU Creating runtime directory /run/user/1000/toolbox
DEBU Old Podman version is 4.5.0
DEBU Migration not needed: Podman version 4.5.0 is unchanged
DEBU Setting up configuration
DEBU Setting up configuration: file /home/dsd/.config/containers/toolbox.conf not found
DEBU Resolving container and image names
DEBU Container: ''
DEBU Distribution (CLI): ''
DEBU Image (CLI): ''
DEBU Release (CLI): ''
DEBU Resolved container and image names
DEBU Container: 'fedora-toolbox-38'
DEBU Image: 'fedora-toolbox:38'
DEBU Release: '38'
DEBU Resolving container and image names
DEBU Container: 'buildstream-dev'
DEBU Distribution (CLI): ''
DEBU Image (CLI): ''
DEBU Release (CLI): ''
DEBU Resolved container and image names
DEBU Container: 'buildstream-dev'
DEBU Image: 'fedora-toolbox:38'
DEBU Release: '38'
DEBU Checking if container buildstream-dev exists
DEBU Inspecting mounts of container buildstream-dev
DEBU Starting container buildstream-dev
DEBU Inspecting entry point of container buildstream-dev
DEBU Entry point PID is a float64
DEBU Entry point of container buildstream-dev is toolbox (PID=0)
Error: invalid entry point PID of container buildstream-dev
Trying with podman for a better log:
$ podman start --attach buildstream-dev
level=debug msg="Running as real user ID 0"
level=debug msg="Resolved absolute path to the executable as /usr/bin/toolbox"
level=debug msg="TOOLBOX_PATH is /usr/bin/toolbox"
level=debug msg="Migrating to newer Podman"
level=debug msg="Setting up configuration"
level=debug msg="Setting up configuration: file /etc/containers/toolbox.conf not found"
level=debug msg="Setting up configuration: file /root/.config/containers/toolbox.conf not found"
level=debug msg="Resolving container and image names"
level=debug msg="Container: ''"
level=debug msg="Distribution (CLI): ''"
level=debug msg="Image (CLI): ''"
level=debug msg="Release (CLI): ''"
level=debug msg="Resolved container and image names"
level=debug msg="Container: 'fedora-toolbox-36'"
level=debug msg="Image: 'fedora-toolbox:36'"
level=debug msg="Release: '36'"
level=debug msg="Creating /run/.toolboxenv"
level=debug msg="Monitoring host"
level=debug msg="Path /run/host/etc exists"
level=debug msg="Resolved /etc/localtime to /run/host/usr/share/zoneinfo/Europe/Zagreb"
level=debug msg="Creating regular file /etc/machine-id"
level=debug msg="Binding /etc/machine-id to /run/host/etc/machine-id"
level=debug msg="Creating directory /run/libvirt"
level=debug msg="Binding /run/libvirt to /run/host/run/libvirt"
level=debug msg="Creating directory /run/systemd/journal"
level=debug msg="Binding /run/systemd/journal to /run/host/run/systemd/journal"
level=debug msg="Creating directory /run/systemd/resolve"
level=debug msg="Binding /run/systemd/resolve to /run/host/run/systemd/resolve"
level=debug msg="Creating directory /run/systemd/sessions"
level=debug msg="Binding /run/systemd/sessions to /run/host/run/systemd/sessions"
level=debug msg="Creating directory /run/systemd/system"
level=debug msg="Binding /run/systemd/system to /run/host/run/systemd/system"
level=debug msg="Creating directory /run/systemd/users"
level=debug msg="Binding /run/systemd/users to /run/host/run/systemd/users"
level=debug msg="Creating directory /run/udev/data"
level=debug msg="Binding /run/udev/data to /run/host/run/udev/data"
level=debug msg="Creating directory /run/udev/tags"
level=debug msg="Binding /run/udev/tags to /run/host/run/udev/tags"
level=debug msg="Creating directory /tmp"
level=debug msg="Binding /tmp to /run/host/tmp"
level=debug msg="Creating directory /var/lib/flatpak"
level=debug msg="Binding /var/lib/flatpak to /run/host/var/lib/flatpak"
level=debug msg="Creating directory /var/lib/systemd/coredump"
level=debug msg="Binding /var/lib/systemd/coredump to /run/host/var/lib/systemd/coredump"
level=debug msg="Creating directory /var/log/journal"
level=debug msg="Binding /var/log/journal to /run/host/var/log/journal"
level=debug msg="Creating directory /sys/fs/selinux"
level=debug msg="Binding /sys/fs/selinux to /usr/share/empty"
level=debug msg="Looking up group for sudo"
level=debug msg="Group for sudo is wheel"
level=debug msg="Modifying user dsd with UID 1000:"
level=debug msg=usermod
level=debug msg=--append
level=debug msg=--groups
level=debug msg=wheel
level=debug msg=--home
level=debug msg=/home/dsd
level=debug msg=--shell
level=debug msg=/bin/bash
level=debug msg=--uid
level=debug msg=1000
level=debug msg=dsd
level=debug msg="Removing password for user dsd"
Error: failed to remove password for user dsd: passwd(1) not found
Looks like passwd is required for all container images intended for use with toolbox: https://github.com/containers/toolbox/issues/181