0

The Red Hat Universal Base Image (UBI) FAQ claims that

8. Will applications built on UBI have access to the same content as images built on a non-UBI base image?

Yes, but accessing non-UBI content requires a Red Hat subscription and renders containers built with non-UBI content non-redistributable.

When I launch a UBI container on a registered, subscribed host, the list of available RPM repositories is different depending on whether I created the host from a RHEL ISO (VirtualBox VM, in this case) or launched an EC2 instance from a RHEL AMI. The UBI container on the EC2 instance does not have access to the full set of RPM package repositories.

For example:

UBI8 container on an RHEL8 EC2 instance

[ec2-user@ip-WWW-XXX-YYY-ZZZ ~]$ podman run --rm -it ubi7 yum repolist all | wc -l
41

UBI8 container on an RHEL8 VirtualBox VM

[neirbowj@rhel8 ~]$ podman run --rm -it ubi8 yum repolist all | wc -l
427

Why is this and how can I modify the EC2 environment so that I can access the full set of RPM package repositories from within a UBI container?

1 Answer 1

0

The reason for this difference is that the RHEL AMIs ship with a non-default value of /etc/rhsm/rhsm.conf:manage_repos = 0. Setting manage_repos = 1 will make a RHEL EC2 instance behave like a RHEL VM with respect to RPM package repository access.

See the current RHSM configuration with:

sudo subscription-manager config --list

Note that square brackets indicate which values are defaults.

Enable RHSM to manage repos with:

sudo subscription-manager config --rhsm.manage_repos=1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .