I have expect script that I need to run under RedHat UBI 8 container. I'm trying to install expect via snap package manager, but I have problem starting snapd.
After issuing systemctl enable --now snapd.socket I get:
System has not been booted with systemd as init system (PID 1). Can't operate.
Failed to connect to bus: Host is down
Can be expect installed into RedHat UBI 8 without snap?
My Dockerfile so far:
FROM registry.access.redhat.com/ubi8/ubi
RUN dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm -y && \
dnf install http://rpms.remirepo.net/enterprise/remi-release-8.rpm -y && \
dnf update -y && \
dnf install -y wget && \
wget http://mirror.centos.org/centos/6/os/x86_64/Packages/squashfs-tools-4.0-5.el6.x86_64.rpm && \
dnf install squashfs-tools-4.0-5.el6.x86_64.rpm -y && \
wget http://mirror.centos.org/centos/8/BaseOS/x86_64/os/Packages/bash-completion-2.7-5.el8.noarch.rpm && \
dnf install -y bash-completion-2.7-5.el8.noarch.rpm && \
dnf install snapd -y && \
systemctl enable --now snapd.socket && \
ln -s /var/lib/snapd/snap /snap && \
snap install expect