unable to run yum from within a Dockerfile

Latest response

I am trying to follow the first steps creating a red Hat based container as its in the documentation

but when I run

docker build -t rhel_httpd .

for my My cool Docker image, with exactly the docker file from the example / documentation, I get

There are no enabled repos.
 Run "yum repolist all" to see the repos you have.
 To enable Red Hat Subscription Management repositories:
     subscription-manager repos --enable <repo>
 To enable custom repositories:
     yum-config-manager --enable <repo>

I am on a red Hat Server, and my system has a subscription,
why do I get this problem?

Thanks for help!

Responses

this problem occurs when using the --graph option for docker to have images stored on an other location than /var/lib/docker

I would say this is a bug, if there is on proper explanation how to use a different docker root dir and using images based on images from the RHEL regestry

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.