We have a Ubuntu Docker container that runs a SSH server that we are trying to port over to Red Hat 8.4. I am trying to install the
openssh-server package using the
dnf package manager via my Dockerfile. The package fails to install with the error
Unable to find a match: openssh-server. Am I trying to install the wrong package? All of the documentation I have been able to find says that is the name of the package.
EDIT: My system is configured with the following 3 repos:
EDIT: Add image of dnf output
It turns out that Red Hat Universal Base Image repos for their Docker images simply do not include openssh-server. I wasn’t able to find a statement from Red Hat as to why, but given how extreme an antipattern it is to run an ssh server in a Docker container, it does make some sense.
If you have a paid Red Hat subscription, you could open a case with Red Hat and ask about having it added. But it’s probably better to get rid of the ssh server entirely.
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.