Skip to content

Commit

Permalink
Add host-registration steps file
Browse files Browse the repository at this point in the history
  • Loading branch information
stejskalleos committed Oct 20, 2021
1 parent 88b0ad5 commit 8218a46
Show file tree
Hide file tree
Showing 9 changed files with 70 additions and 141 deletions.
23 changes: 1 addition & 22 deletions guides/common/modules/con_basic-content-management-workflow.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -58,28 +58,7 @@ Use the following procedure to create an activation key that you can use to subs

Use the following procedure to register an existing CentOS Stream host to {Project}

.Procedure
. Generate registration command
+
UI: In the {ProjectWebUI}, navigate to *Hosts > Register Host*, select one or more Activation Keys and generate the registration command.
Or you can generate command via API:
+
[options="nowrap" subs="+quotes,attributes"]
----
# hammer host-registration generate-command --activation-keys your-key
# curl -X POST https://{foreman-example-com}/api/registration_commands \
--user username:password \
-H 'Content-Type: application/json' -d '{\"activation_key\":\"your-key\",\"organization_id\":\"organization_id\"}'"
----
. Log on to the host you want register and run the command
. After registration, enable content from {ProjectServer}:
+
[options="nowrap" subs="+quotes"]
----
# yum repolist
----
. Check the `/etc/yum.repos.d/redhat.conf` and ensure that the appropriate repositories have been enabled.
include::proc_host_registration_steps.adoc[leveloffset=+1]

== Using Content Views

Expand Down
44 changes: 44 additions & 0 deletions guides/common/modules/proc_host_registration_steps.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
.Procedure

. Generate registration command
+
UI: In the {ProjectWebUI}, navigate to *Hosts > Register Host* and generate the registration command.
+
Or you can generate command via API:
ifdef::foreman-el,foreman-deb[]
+
[options="nowrap" subs="+quotes,attributes"]
----
# hammer host-registration generate-command

# or manually:

# curl -X POST https://{foreman-example-com}/api/registration_commands \
--user username:password \
-H 'Content-Type: application/json'
----
endif::[]
ifdef::katello,satellite[]
+
[options="nowrap" subs="+quotes,attributes"]
----
# hammer host-registration generate-command --activation-keys your-key

# or manually:

# curl -X POST https://{foreman-example-com}/api/registration_commands \
--user username:password \
-H 'Content-Type: application/json' \
-d '{\"activation_keys\":\"your-key\"}'"
----
endif::[]
ifdef::katello,satellite[]
+
Use an activation key to simplify specifying the environments.
For more information about activation keys, see {ContentManagementDocURL}Managing_Activation_Keys_content-management[Managing Activation Keys] in the _Content Management Guide_.
endif::[]
+
For more information about registration see {ManagingHostsDocURL}registering-a-host_managing-hosts[Registering a Host to {ProjectName}].

. Log on to the host you want register and run the command
. Check the `/etc/yum.repos.d/redhat.conf` and ensure that the appropriate repositories have been enabled.
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,5 @@ For more information on manifests and repositories, see {ContentManagementDocURL
* The base operating system on which you want to install {SmartProxyServer} must not be configured to use a proxy to connect to the Red Hat CDN.
* You must configure the host and network-based firewalls accordingly.
For more information, see {InstallingSmartProxyDocURL}capsule-ports-and-firewalls-requirements_{smart-proxy-context}[Ports and Firewalls Requirements].
* You must have a {ProjectServer} user name and password.
For more information, see {AdministeringDocURL}Configuring_External_Authentication_admin[Configuring External Authentication] in _Administering {ProjectName}_.

.Procedure

. Generate registration command
+
UI: In the {ProjectWebUI}, navigate to *Hosts > Register Host*, select one or more Activation Keys and generate the registration command.
Or you can generate command via API:
+
[options="nowrap" subs="+quotes,attributes"]
----
# hammer host-registration generate-command --activation-keys your-key
# curl -X POST https://{foreman-example-com}/api/registration_commands \
--user username:password \
-H 'Content-Type: application/json' -d '{\"activation_key\":\"your-key\",\"organization_id\":\"organization_id\"}'"
----
. Log on to the {SmartProxy} you want register and run the command
include::proc_host_registration_steps.adoc[leveloffset=+1]
17 changes: 1 addition & 16 deletions guides/common/modules/proc_registering-to-satellite-server.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,4 @@ For more information, see {InstallingSmartProxyDocURL}capsule-ports-and-firewall
* You must have a {ProjectServer} user name and password.
For more information, see {AdministeringDocURL}Configuring_External_Authentication_admin[Configuring External Authentication] in _Administering {ProjectName}_.

.Procedure

. Generate registration command
+
UI: In the {ProjectWebUI}, navigate to *Hosts > Register Host*, select one or more Activation Keys and generate the registration command.
Or you can generate command via API:
+
[options="nowrap" subs="+quotes,attributes"]
----
# hammer host-registration generate-command --activation-keys your-key
# curl -X POST https://{foreman-example-com}/api/registration_commands \
--user username:password \
-H 'Content-Type: application/json' -d '{\"activation_key\":\"your-key\",\"organization_id\":\"organization_id\"}'"
----
. Log on to the {SmartProxyServer} you want register and run the command
include::proc_host_registration_steps.adoc[leveloffset=+1]
Original file line number Diff line number Diff line change
Expand Up @@ -8,25 +8,7 @@ The kickstart provisioning templates in {ProjectNameX} contain commands to regis
* Registering existing Red Hat Enterprise Linux hosts.
Configure Subscription Manager to use {ProjectServer} for registration and specify the activation key when running the `subscription-manager register` command.

.Procedure

To use an activation key for host registration with an existing Red Hat Enterprise Linux 7 host to {ProjectServer}, complete the following steps:

. Generate registration command
+
UI: In the {ProjectWebUI}, navigate to *Hosts > Register Host*, select one or more Activation Keys and generate the registration command.
Or you can generate command via API:
+
[options="nowrap" subs="+quotes,attributes"]
----
# hammer host-registration generate-command --activation-keys your-key
# curl -X POST https://{foreman-example-com}/api/registration_commands \
--user username:password \
-H 'Content-Type: application/json' -d '{\"activation_key\":\"your-key\",\"organization_id\":\"organization_id\"}'"
----
. Log on to the host you want register and run the command
. Check the `/etc/yum.repos.d/redhat.conf` and ensure that the appropriate repositories have been enabled.
include::proc_host_registration_steps.adoc[leveloffset=+1]

.Multiple Activation Keys

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,25 +13,10 @@ To register clients, proceed to one of the following procedures:
[id='registering-clients-using-the-host-registration']
== {ProjectName} host registration

.Procedure

. Generate registration command
+
UI: In the {ProjectWebUI}, navigate to *Hosts > Register Host*, select one or more Activation Keys and generate the registration command.
Or you can generate command via API:
+
[options="nowrap" subs="+quotes,attributes"]
----
# hammer host-registration generate-command --activation-keys your-key
# curl -X POST https://{foreman-example-com}/api/registration_commands \
--user username:password \
-H 'Content-Type: application/json' -d '{\"activation_key\":\"your-key\",\"organization_id\":\"organization_id\"}'"
----
. Log on to the {SmartProxy} you want register and run the command
include::../common/modules/proc_host_registration_steps.adoc[leveloffset=+1]

[id='registering-clients-using-the-bootstrap-script']
== **Deprecated** Registering Clients Using the Bootstrap Script
== **(Deprecated)** Registering Clients Using the Bootstrap Script

To register clients, enter the following command on the client.
You must complete the registration procedure for each client.
Expand Down Expand Up @@ -80,7 +65,7 @@ For more information, see {ManagingHostsDocURL}registering-a-host-to-satellite-u
The script prompts for the password corresponding to the {Project} user name you entered with the `--login` option.

[id='registering-clients-manually']
== **Deprecated** Registering Clients Manually with katello-ca-consumer rpm
== **(Deprecated)** Registering Clients Manually with katello-ca-consumer rpm

To register clients manually, complete the following procedure on each client that you register.

Expand Down
3 changes: 0 additions & 3 deletions guides/doc-Managing_Hosts/topics/Registering_Hosts.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ You can also register Atomic Hosts to {ProjectServer} or {SmartProxyServer}.
Use one of the following procedures to register a host:

* xref:registering-a-host_{context}[]
* xref:registering-a-host-to-satellite[]
* xref:registering-an-atomic-host-to-satellite[]
* xref:registering-a-host-to-satellite-using-the-bootstrap-script[]

Expand Down Expand Up @@ -60,8 +59,6 @@ include::proc_registering-a-host.adoc[leveloffset=+1]

include::ref_customizing-the-registration-templates.adoc[leveloffset=+2]

include::proc_registering-a-host-to-satellite-manually.adoc[leveloffset=+1]

include::proc_registering-an-atomic-host-to-satellite.adoc[leveloffset=+1]

include::proc_registering-a-host-to-satellite-using-the-bootstrap-script.adoc[leveloffset=+1]
Expand Down

This file was deleted.

19 changes: 19 additions & 0 deletions guides/doc-Managing_Hosts/topics/proc_registering-a-host.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ ifdef::satellite,orcharhino[]
* You must have an activation key created.
* Optional: If you want to register hosts to Red{nbsp}Hat Insights, you must synchronize the `{RepoRHEL7Server}` repository and make it available in the activation key that you use.
This is required to install the `insights-client` package on hosts.
* {ProjectServer}, any {SmartProxyServer}s, and all hosts must be synchronized with the same NTP server, and have a time synchronization tool enabled and running.
* The daemon *rhsmcertd* must be running on the hosts.
* An activation key must be available for the host.
For more information, see {ContentManagementDocURL}Managing_Activation_Keys_content-management[Managing Activation Keys] in the _Content Management Guide_.
* Subscription Manager must be version 1.10 or later.
The package is available in the standard Red{nbsp}Hat Enterprise Linux repository.
endif::[]
* Optional: If you want to register hosts through {SmartProxy}, ensure that the *Registration* feature is enabled on this {SmartProxy}.
+
Expand Down Expand Up @@ -113,3 +119,16 @@ Copy the CA file to the `/etc/pki/ca-trust/source/anchors/` directory on hosts a
# update-ca-trust
----
. On the hosts that you want to register, enter the `curl` command as `root`.

ifdef::katello,satellite,orcharhino[]
[NOTE]
====
For Red{nbsp}Hat Enterprise Linux 6.3 hosts, the release version defaults to Red{nbsp}Hat Enterprise{nbsp}Linux{nbsp}6 Server and needs to be pointed to the 6.3 repository:
. In the {ProjectWebUI}, navigate to *Hosts* > *Content Hosts*.
. Select the check box next to the host that needs to be changed.
. From the *Select Action* list, select *Set Release Version*.
. From the *Release Version* list, select *6.3*.
. Click *Done*.
====
endif::[]

0 comments on commit 8218a46

Please sign in to comment.