Created
May 19, 2017 19:17
-
-
Save javilinux/9dd679fb3f0e69b2bdf2f2ceb9c125e5 to your computer and use it in GitHub Desktop.
subscription-manager in containers in non-RHEL hosts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
touch /usr/share/rhel/secrets/ | |
mkdir -p /usr/share/rhel/secrets/rhsm | |
mkdir -p /usr/share/rhel/secrets/rhsm/ca | |
mkdir -p /usr/share/rhel/secrets/etc-pki-entitlement | |
docker run -it registry.access.redhat.com/rhel7/rhel:latest | |
docker ps -lq | |
sudo docker cp $id:/etc/rhsm/rhsm.conf /usr/share/rhel/secrets/rhsm/ | |
sudo docker cp $id:/etc/rhsm/ca/redhat-uep.pem /usr/share/rhel/secrets/rhsm/ca/ | |
From https://access.redhat.com/management/consumers/ | |
sudo cp Downloads/$cert.pem /usr/share/rhel/secrets/etc-pki-entitlement/entitlement.pem | |
sudo cp Downloads/$cert.pem /usr/share/rhel/secrets/etc-pki-entitlement/entitlement-key.pem | |
Based on https://patrick.uiterwijk.org/blog/2016/10/6/rhel-containers-on-non-rhel-hosts |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment