Chapter 9. Managing custom repositories
Chapter 9. Managing custom repositories Custom repositories extend the images you build in the edge management application to packages beyond those that Red Hat provides. You can customize the images with custom repositories and custom packages that fit your specific business case. For example, you can add packages from the Extra Packages for Enterprise Linux (EPEL), or any compatible package list. You can update your existing images by adding or removing packages from these custom repositories. You can also remove repositories, and also add repositories from the popular repositories. 9.1. Adding a custom repository To add packages from the third-party repository to your customized images, you must first define your repository with third-party information. Prerequisites You have a RHEL subscription. You have administrator access to the Red Hat Hybrid Cloud Console web user interface or repository administrator role. You have the URL for your custom repository. Procedure Access Hybrid Cloud Console . Click Red Hat Insights > RHEL > Content > Repositories . The Custom repositories dashboard appears. Click Add repositories . The Add custom repositories wizard opens. Enter the following information: NAME - mandatory. URL - mandatory. In the Restrict architecture drop-down menu, select an architecture. You can allow all the architectures or restrict one to your system architecture to prevent incorrect repositories availability. In the Restrict OS version drop-down menu select an operating system (OS). You can allow all the RHEL versions or select one for your system version to prevent incorrect repositories being available. GPG key - upload the .txt file with a GPG key or paste the URL or value of an existing GPG key. The GPG key verifies the signed packages of a repository. If you do not provide the GPG key for a repository, your system cannot perform the verification. If you want to add another repository, click the Add another repository button and repeat step 3. Click Save . The Red Hat Hybrid Cloud Console validates the project status. If your repository is marked as Invalid , check the repository URL that you added. Verification Open the list of custom repositories and verify that the repository you added is listed. Troubleshooting If your repository is marked as Invalid , check the repository URL that you added. 9.2. Adding a custom repository to an image You can add a custom repository and the associated packages to an image after it has been created. Prerequisites You have a Red Hat Hybrid Cloud Console account. You have built an image in the Red Hat Hybrid Cloud Console and registered it with rhc client that contains custom repositories. You have added one or more custom repositories. See Adding a custom repository for more information. Procedure Access Hybrid Cloud Console . Click Red Hat Insights > RHEL > Inventory > Images . The Insights Image Builder dashboard appears. Click the Immutable (OSTree) tab. Click the name of the image you want to update. On the image details page, click Actions > Create new version . The Update image wizard opens. Click on both the Details and Options page to view the custom repositories that have been added to the image. On the Content page, perform the following actions: On the Custom repositories page, select the linked custom repositories you want to add. Click . On the Additional custom packages page, search and choose the packages you want to add from the repository. If you are using the Fedora example repository https://dl.fedoraproject.org/pub/archive/fedora/linux/releases/29/Everything/x86_64/os/ , enter waf-python3 to add the package. Click . On the Review page, review your changes and click Update image . step After the image update completes, you can update systems that are using that image. See Updating a system for more information. 9.3. Removing a custom repository from an image You can remove custom repositories and the associated packages from an image after it has been created. When you remove a custom repository, the packages associated with that custom repository will also be removed from the image. Prerequisites You have a Red Hat Hybrid Cloud Console account. You have built an image in the Red Hat Hybrid Cloud Console and registered it with Remote Host Configuration and Management that contains custom repositories. You have added one or more custom repositories. See Adding a custom repository to the edge management application for more information. Procedure Access Hybrid Cloud Console . Click the Settings icon (⚙) in the top right and, from the menu, select Settings . On the Settings menu, select Repositories . From the Your repositories tab, select the Custom . From the available repositories, select the repository to delete. Click the More options (...) icon and choose Delete . From the Remove repository window, confirm that you want to delete the repository by clicking Remove .