问题原文
原帖链接 · Al F · CC BY-SA 3.0
I'm trying to get a rhel container running on a simple docker host. The docker host is rhel7, fully subscribed properly. I wanted to use the pure docker engine packages instead of the ones that came with redhat, but unfortunately it seems that subscription management and usage is not available once I switched to the pure docker engine. I can run the image without issue, but once I try to use yum, no luck:
# docker run --rm -it registry.access.redhat.com/rhel7 /bin/sh
sh-4.2# yum update
Loaded plugins: ovl, product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
There are no enabled repos.
Run "yum repolist all" to see the repos you have.
You can enable repos with yum-config-manager --enable <repo>
Yum and subscription stuff works fine on the main host system. Anyone know of a way to get a redhat container working (and able to pull packages) using the pure engine and host's credentials?
Thanks!
Al
已采纳解答
原帖链接 · dawud · CC BY-SA 3.0
The "official" way to develop containers (or apps to be deployed in containers) on an RHEL7 box is using the Container Development Kit.
Red Hat Container Development Kit provides a pre-built Container Development Environment based on Red Hat Enterprise Linux to help you develop container-based (sometimes called Docker) applications quickly. The containers you build can be easily deployed on any Red Hat container host or platform, including: Red Hat Enterprise Linux, Red Hat Enterprise Linux Atomic Host, and our platform-as-a-service solution, OpenShift Enterprise 3.
Italics are mine.
A subscribed RHEL7 (even a Developer subscription) will transparently let you use the RHEL repositories available to your subscription from the containers.
摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。
