Chapter 8. Managing Red Hat subscriptions with cloud-init
To register your system with Red Hat Subscription Management, you can use the rh_subscription directive in cloud-init. Configure the directive with username and password, activation key and organization, or a custom server hostname.
- Using the
defaultoption Under
rh_subscription, add yourusernameandpassword.rh_subscription: username: <example@redhat.com> password: <example_password>- Using the
activation-keyandorgoptions Under
rh_subscription, add youractivation keyandorgnumber.rh_subscription: activation-key: <example_key> org: <example_id>- Using the
server-hostnameoption You can set a server hostname in the
/etc/rhsm/rhsm.conffile. Underrh_subscription, add yourusername,password, andserver-hostname.rh_subscription: username: <example@redhat.com> password: <example_password> server-hostname: <test.example.com>