content-sources-backend

Introspection

Background

One of the purposes of the content-sources application is to provide a central registry of repositories used by an organization, alongside information about those repositories. This information includes what packages, advisories, and package groups are included within the repository. If a service needs to install content from an introspected repository it needs to use the external URL to pull the RPMs directly, no RPMs are actually hosted by our service.

What is introspection?

Introspection is the process of learning about a yum repository, including details about packages, advisories/errata, and package groups.

This information is stored within the database and can be fetched or searched using the API.

How often does introspection occur?

Repositories are attempted to be introspected once per day. A job is run hourly that attempts to introspect any repos that have not been introspected successfully in the last 24 hours.

Introspection can also be triggered directly using the API & UI, or using the command line:

How is repository introspection data used?

Image builder can build images using data from the content-sources API. When building an image, Image Builder will list repositories within the user’s organization and allow the user to search for packages within their selected repositories.

What does the introspection process look like?

For most of the heavy lifting, content-sources uses yummy for downloading and parsing yum metadata. Yummy downloads the ./repodata/repomd.xml file within the yum repository. This file provides an index of other files available. It will then download the following files:

Once the data is downloaded, it is saved within the database.