Skip to content
This repository has been archived by the owner on Nov 5, 2024. It is now read-only.

Document how to create entitlement subscription secret #273

Merged
merged 1 commit into from
Jun 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/modules/ROOT/nav-how-to-guides.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
*** xref:how-to-guides/configuring-builds/proc_defining_component_relationships.adoc[Defining component relationships]
*** xref:how-to-guides/configuring-builds/proc_preventing_redundant_rebuilds.adoc[Preventing redundant rebuilds]
*** xref:how-to-guides/configuring-builds/proc_custom-tags.adoc[Using custom tags]
*** xref:how-to-guides/configuring-builds/proc_entitlement_subscription.adoc[Using Red Hat entitlement subscription]
** Testing your application
*** xref:how-to-guides/testing_applications/con_test-overview.adoc[Overview of {ProductName} tests]
*** xref:how-to-guides/testing_applications/surface-level_tests.adoc[Surface-level tests]
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
:_content-type: PROCEDURE
:troubleshooting_builds:

[id="entitlement_subscription_{context}"]
= Using Red Hat entitlement subscription

Entitlement subscription allows users to install RPMs that are not accessible without it. In order to use it in your builds, you must have access to an entitlement subscription
and possess the neccessary entitlement certificate files. To obtain them, review https://developers.redhat.com/articles/2022/01/24/create-entitled-builds-red-hat-subscriptions-openshift[Subscription benefits for secure deployments] guide.

Once you have the *<entitlement-id>.pem* and *<entitlement-id>-key.pem* files, you will need to create a secret in your Konflux namespace. You can do it in two ways:

. <<Create-entitlement-secret-through-the-UI>>
. <<Create-entitlement-secret-through-console>>


[[Create-entitlement-secret-through-the-UI]]
== Create entitlement secret through the UI

1. Access the Secrets section in the konflux UI and click on *Add secret*.
2. Set the secret name to *etc-pki-entitlement*.
3. Add the first key with the name *<entitlement-id>-key.pem* and and set the value to the contents of the key file.
4. Add a second key with the name *<entitlement-id>.pem* and set the value to the contents of the certificate file.
5. Save the secret by clicking *Add secret*

[[Create-entitlement-secret-through-console]]
== Create entitlement secret through console

Alternatively, you can create the secret through the CLI. After logging into your cluster and navigating to your namespace, run the following command:

----
oc create secret generic etc-pki-entitlement -n <your-tenant> --from-file <entitlement-id>-key.pem --from-file <entitlement-id>.pem
----
Loading