Managing content in automation hub
Create and manage collections, content and repositories in automation hub
Abstract
Providing feedback on Red Hat documentation
If you have a suggestion to improve this documentation, or find an error, you can contact technical support at https://access.redhat.com to open a request.
Chapter 1. Red Hat Certified, validated, and Ansible Galaxy content in automation hub
Ansible Certified Content Collections are included in your subscription to Red Hat Ansible Automation Platform. Red Hat Ansible content includes two types of content: Ansible Certified Content Collections and Ansible validated content. Using Ansible automation hub, you can access and curate a unique set of collections from all forms of Ansible content.
Red Hat Ansible content contains two types of content:
- Ansible Certified Content Collections
- Ansible validated content collections
Ansible validated collections are available in your private automation hub through the Platform Installer. When you download Red Hat Ansible Automation Platform with the bundled installer, validated content is pre-populated into the private automation hub by default, but only if you enable the private automation hub as part of the inventory.
If you are not using the bundle installer, you can use a Red Hat supplied Ansible playbook to install validated content. For further information, see Ansible validated content.
You can update these collections manually by downloading their packages.
Why certify Ansible collections?
The Ansible certification program enables a shared statement of support for Red Hat Ansible Certified Content between Red Hat and the ecosystem partner. An end customer, experiencing trouble with Ansible and certified partner content, can open a support ticket, for example, a request for information, or a problem with Red Hat, and expect the ticket to be resolved by Red Hat and the ecosystem partner.
Red Hat offers go-to-market benefits for Certified Partners to grow market awareness, generate demand, and sell collaboratively.
Red Hat Ansible Certified Content Collections are distributed through Ansible automation hub (subscription required), a centralized repository for jointly supported Ansible Content. As a certified partner, publishing collections to Ansible automation hub provides end customers the power to manage how trusted automation content is used in their production environment with a well-known support life cycle.
For more information about getting started with certifying a solution, see Red Hat Partner Connect.
How do I get a collection certified?
For instructions on certifying your collection, see the Ansible certification policy guide on Red Hat Partner Connect.
How does the joint support agreement on Certified Collections work?
If a customer raises an issue with the Red Hat support team about a certified collection, Red Hat support assesses the issue and checks whether the problem exists within Ansible or Ansible usage. They also check whether the issue is with a certified collection. If there is a problem with the certified collection, support teams transfer the issue to the vendor owner of the certified collection through an agreed upon tool such as TSANet.
Can I create and certify a collection containing only Ansible Roles?
You can create and certify collections that contain only roles. Current testing requirements are focused on collections containing modules, and additional resources are currently in progress for testing collections only containing roles. Contact ansiblepartners@redhat.com for more information.
1.1. Synchronizing Ansible Content Collections in automation hub
As of the 2.4 release you can still synchronize content, but synclists are deprecated, and will be removed in a future version.
To synchronize content, you can now upload a manually-created requirements file from the rh-certified remote.
Remotes are configurations that enable you to synchronize content to your custom repositories from an external collection source.
You can use Ansible automation hub to distribute the relevant Red Hat Ansible Certified Content Collections to your users by creating synclists or a requirements file. For more information about using requirements files, see Install multiple collections with a requirements file in the Using Ansible collections guide.
1.1.1. Explanation of Red Hat Ansible Certified Content Collections synclists
A synclist is a curated group of Red Hat Certified Collections that is assembled by your organization administrator. It synchronizes with your local Ansible automation hub. Use synclists to manage only the content that you want and exclude unnecessary collections. Design and manage your synclist from the content available as part of Red Hat content on console.redhat.com
Each synclist has its own unique repository URL that you can use to designate as a remote source for content in automation hub. You securely access each synclist by using an API token.
1.1.2. Creating a synclist of Red Hat Ansible Certified Content Collections
You can create a synclist of curated Red Hat Ansible Certified Content in Ansible automation hub on console.redhat.com. Your synclist repository is located on the automation hub navigation panel under
→ , which is updated whenever you manage content within Ansible Certified Content Collections.All Ansible Certified Content Collections are included by default in your initial organization synclist.
Prerequisites
- You have a valid Ansible Automation Platform subscription.
- You have Organization Administrator permissions for console.redhat.com.
The following domain names are part of either the firewall or the proxy’s allowlist. They are required for successful connection and download of collections from automation hub or Galaxy server:
-
galaxy.ansible.com
-
cloud.redhat.com
-
console.redhat.com
-
sso.redhat.com
-
Ansible automation hub resources are stored in Amazon Simple Storage. The following domain names must be in the allow list:
-
automation-hub-prd.s3.us-east-2.amazonaws.com
-
ansible-galaxy.s3.amazonaws.com
-
- SSL inspection is disabled either when using self signed certificates or for the Red Hat domains.
Procedure
-
Log in to
console.redhat.com
. - Navigate to → .
- Set the toggle switch on each collection to exclude or include it on your synclist.
- To initiate the remote repository synchronization, navigate to automation hub and select → .
- Click the ⋮ and select Sync to initiate the remote repository synchronization to your private automation hub. icon
- Optional: If your remote repository is already configured, update the collections content that you made available to local users by manually synchronizing Red Hat Ansible Certified Content Collections to your private automation hub.
1.2. Configuring Ansible automation hub remote repositories to synchronize content
Use remote configurations to configure your private automation hub to synchronize with Ansible Certified Content Collections hosted on console.redhat.com
or with your collections in Ansible Galaxy.
As of the 2.4 release you can still synchronize content, but synclists are deprecated, and will be removed in a future version.
To synchronize content, you can now upload a manually-created requirements file from the rh-certified remote.
Remotes are configurations that allow you to synchronize content to your custom repositories from an external collection source.
What’s the difference between Ansible Galaxy and Ansible automation hub?
Collections published to Ansible Galaxy are the latest content published by the Ansible community and have no joint support claims associated with them. Ansible Galaxy is the recommended frontend directory for the Ansible community accessing content.
Collections published to Ansible automation hub are targeted for joint customers of Red Hat and selected partners. Customers need an Ansible subscription to access and download collections on Ansible automation hub. A certified collection means that Red Hat and partners have a strategic relationship in place and are ready to support joint customers, and may have had additional testing and validation done against them.
How do I request a namespace on Ansible Galaxy?
To request a namespace through an Ansible Galaxy GitHub issue, follow these steps:
- Send an email to ansiblepartners@redhat.com
- Include the GitHub username used to sign up on Ansible Galaxy.
You must have logged in at least once for the system to validate.
After users are added as administrators of the namespace, you can use the self-serve process to add more administrators.
Are there any restrictions for Ansible Galaxy namespace naming?
Collection namespaces must follow python module name convention. This means collections should have short, all lowercase names. You can use underscores in the collection name if it improves readability.
1.2.1. Reasons to create remote configurations
Each remote configuration located in community and rh-certified repository about when the repository was last updated. You can add new content to Ansible automation hub at any time using the Edit and Sync features included on the → page.
→ provides information for both the1.2.2. Retrieving the Sync URL and API token for your Red Hat Certified Collection
You can synchronize Ansible Certified Content Collections curated by your organization from console.redhat.com
to your private automation hub. The API token is a secret token used to protect your content.
Prerequisites
- You have organization administrator permissions to create the synclist on console.redhat.com.
Procedure
-
Log in to
console.redhat.com
as an organization administrator. - Navigate to → .
- Under Offline token, click .
- Click to copy the API token.
- Paste the API token into a file and store in a secure location.
1.2.3. Configuring the rh-certified remote repository and synchronizing Red Hat Ansible Certified Content Collection
You can edit the rh-certified remote repository to synchronize collections from automation hub hosted on console.redhat.com to your private automation hub. By default, your private automation hub rh-certified
repository includes the URL for the entire group of Ansible Certified Content Collections.
To use only those collections specified by your organization, a private automation hub administrator can upload manually-created requirements files from the rh-certified
remote.
For more information about using requirements files, see Install multiple collections with a requirements file in the Using Ansible collections guide.
If you have collections A
, B
, and C
in your requirements file, and a new collection X
is added to console.redhat.com that you want to use, you must add X
to your requirements file for private automation hub to synchronize it.
Prerequisites
- You have valid Modify Ansible repo content permissions. For more information on permissions, see Configuring user access for your private automation hub.
- You have retrieved the Sync URL and API Token from the automation hub hosted service on console.redhat.com.
- You have configured access to port 443. This is required for synchronizing certified collections. For more information, see the automation hub table in the Network ports and protocols chapter of the Red Hat Ansible Automation Platform Planning Guide.
Procedure
- Log in to your private automation hub.
- From the navigation panel, select → .
- In the rh-certified remote repository, click the icon ⋮ and click .
- In the URL field, paste the Sync URL.
- In the Token field, paste the token you acquired from console.redhat.com.
Click
.You can now synchronize collections between your organization synclist on console.redhat.com and your private automation hub.
- Click the ⋮ and select Sync. icon
Verification
The Sync status notification updates to notify you that the Red Hat Certified Content Collections synchronization is complete.
- Select Red Hat Certified from the collections content drop-down list to confirm that your collections content has synchronized successfully.
1.2.4. Configuring the community remote repository and syncing Ansible Galaxy collections
You can edit the community remote repository to synchronize chosen collections from Ansible Galaxy to your private automation hub. By default, your private automation hub community repository directs to galaxy.ansible.com/api/
.
Prerequisites
- You have Modify Ansible repo content permissions. For more information on permissions, see Configuring user access for your private automation hub.
You have a
requirements.yml
file that identifies those collections to synchronize from Ansible Galaxy as in the following example:Requirements.yml example
collections: # Install a collection from Ansible Galaxy. - name: community.aws version: 5.2.0 source: https://galaxy.ansible.com
Procedure
- Log in to automation hub.
- From the navigation panel, select → .
- In the Community remote, click the icon ⋮ and select Edit.
-
In the YAML requirements field, click and locate the
requirements.yml
file on your local machine. Click
.You can now synchronize collections identified in your
requirements.yml
file from Ansible Galaxy to your private automation hub.- Click the ⋮ and select Sync to sync collections from Ansible Galaxy and Ansible automation hub. icon
Verification
The Sync status notification updates to notify you of completion or failure of Ansible Galaxy collections synchronization to your Ansible automation hub.
- Select Community from the collections content drop-down list to confirm successful synchronization.
1.2.5. Configuring proxy settings
If your private automation hub is behind a network proxy, you can configure proxy settings on the remote to sync content located outside of your local network.
Prerequisites
- You have valid Modify Ansible repo content permissions. For more information on permissions, see Configuring user access for your private automation hub.
- You have a proxy URL and credentials from your local network administrator.
Procedure
- Log in to private automation hub.
- From the navigation panel, select → .
- In either the rh-certified or Community remote, click the icon ⋮ and select Edit.
- Expand the Show advanced options drop-down menu.
- Enter your proxy URL, proxy username, and proxy password in the appropriate fields.
- Click .
1.3. Collections and content signing in private automation hub
As an automation administrator for your organization, you can configure private automation hub for signing and publishing Ansible content collections from different groups within your organization.
For additional security, automation creators can configure Ansible-Galaxy CLI to verify these collections to ensure that they have not been changed after they were uploaded to automation hub.
1.3.1. Configuring content signing on private automation hub
To successfully sign and publish Ansible Certified Content Collections, you must configure private automation hub for signing.
Prerequisites
- Your GnuPG key pairs have been securely set up and managed by your organization.
- Your public-private key pair has proper access for configuring content signing on private automation hub.
Procedure
Create a signing script that accepts only a filename.
NoteThis script acts as the signing service and must generate an ascii-armored detached
gpg
signature for that file using the key specified through thePULP_SIGNING_KEY_FINGERPRINT
environment variable.The script prints out a JSON structure with the following format.
{"file": "filename", "signature": "filename.asc"}
All the file names are relative paths inside the current working directory. The file name must remain the same for the detached signature.
Example:
The following script produces signatures for content:
#!/usr/bin/env bash FILE_PATH=$1 SIGNATURE_PATH="$1.asc" ADMIN_ID="$PULP_SIGNING_KEY_FINGERPRINT" PASSWORD="password" # Create a detached signature gpg --quiet --batch --pinentry-mode loopback --yes --passphrase \ $PASSWORD --homedir ~/.gnupg/ --detach-sign --default-key $ADMIN_ID \ --armor --output $SIGNATURE_PATH $FILE_PATH # Check the exit status STATUS=$? if [ $STATUS -eq 0 ]; then echo {\"file\": \"$FILE_PATH\", \"signature\": \"$SIGNATURE_PATH\"} else exit $STATUS fi
After you deploy a private automation hub with signing enabled to your Ansible Automation Platform cluster, new UI additions are displayed in collections.
Review the Ansible Automation Platform installer inventory file for options that begin with
automationhub_*
.[all:vars] . . . automationhub_create_default_collection_signing_service = True automationhub_auto_sign_collections = True automationhub_require_content_approval = True automationhub_collection_signing_service_key = /abs/path/to/galaxy_signing_service.gpg automationhub_collection_signing_service_script = /abs/path/to/collection_signing.sh
The two new keys (automationhub_auto_sign_collections and automationhub_require_content_approval) indicate that the collections must be signed and approved after they are uploaded to private automation hub.
1.3.2. Using content signing services in private automation hub
After you have configured content signing on your private automation hub, you can manually sign a new collection or replace an existing signature with a new one. When users download a specific collection, this signature indicates that the collection is for them and has not been modified after certification.
You can use content signing on private automation hub in the following scenarios:
- Your system does not have automatic signing configured and you must use a manual signing process to sign collections.
- The current signatures on the automatically configured collections are corrupted and need new signatures.
- You need additional signatures for previously signed content.
- You want to rotate signatures on your collections.
Procedure
- Log in to your Ansible Automation Platform.
- From the navigation panel, select → . The Approval dashboard opens and displays a list of collections.
- Click for each collection that you want to sign.
Verification
- Verify that the collections you signed and manually approved are displayed in the Collections tab.
1.3.3. Downloading signature public keys
After you sign and approve collections, download the signature public keys from the automation hub UI. You must download the public key before you add it to the local system keyring.
Procedure
- Log in to your automation hub.
From the navigation panel, select
. The Signature Keys dashboard displays a list of multiple keys: collections and container images.-
To verify collections, download the key prefixed with
collections-
. -
To verify container images, download the key prefixed with
container-
.
-
To verify collections, download the key prefixed with
Choose one of the following methods to download your public key:
- Select the menu icon and click to download the public key.
- Select the public key from the list and click the Copy to clipboard icon.
- Click the drop-down menu under the Public Key tab and copy the entire public key block.
Use the public key that you copied to verify the content collection that you are installing.
1.3.4. Configuring Ansible-Galaxy CLI to verify collections
You can configure Ansible-Galaxy CLI to verify collections. This ensures that downloaded collections are approved by your organization and have not been changed after they were uploaded to automation hub.
If a collection has been signed by automation hub, the server provides ASCII armored, GPG-detached signatures to verify the authenticity of MANIFEST.json
before using it to verify the collection’s contents. You must opt into signature verification by configuring a keyring for ansible-galaxy
or providing the path with the --keyring
option.
Prerequisites
- Signed collections are available in automation hub to verify signature.
- Certified collections can be signed by approved roles within your organization.
- Public key for verification has been added to the local system keyring.
Procedure
To import a public key into a non-default keyring for use with
ansible-galaxy
, run the following command.gpg --import --no-default-keyring --keyring ~/.ansible/pubring.kbx my-public-key.asc
NoteIn addition to any signatures provided by the automation hub, signature sources can also be provided in the requirements file and on the command line. Signature sources should be URIs.
To verify the collection name provided on the CLI with an additional signature, run the following command:
ansible-galaxy collection install namespace.collection --signature https://examplehost.com/detached_signature.asc --signature file:///path/to/local/detached_signature.asc --keyring ~/.ansible/pubring.kbx
You can use this option multiple times to provide multiple signatures.
Confirm that the collections in a requirements file list any additional signature sources following the collection’s signatures key, as in the following example.
# requirements.yml collections: - name: ns.coll version: 1.0.0 signatures: - https://examplehost.com/detached_signature.asc - file:///path/to/local/detached_signature.asc ansible-galaxy collection verify -r requirements.yml --keyring ~/.ansible/pubring.kbx
When you install a collection from automation hub, the signatures provided by the server are saved along with the installed collections to verify the collection’s authenticity.
-
(Optional) If you need to verify the internal consistency of your collection again without querying the Ansible Galaxy server, run the same command you used previously using the
--offline
option.
Are there any recommendations for collection naming?
Create a collection with company_name.product
format. This format means that multiple products can have different collections under the company namespace.
How do I get a namespace on Ansible automation hub?
By default namespaces used on Ansible Galaxy are also used on Ansible automation hub by the Ansible partner team. For any queries and clarifications contact ansiblepartners@redhat.com.
1.4. Ansible validated content
Red Hat Ansible Automation Platform includes Ansible validated content, which complements existing Red Hat Ansible Certified Content.
Ansible validated content provides an expert-led path for performing operational tasks on a variety of platforms from both Red Hat and our trusted partners.
1.4.1. Configuring validated collections with the installer
When you download and run the bundle installer, certified and validated collections are automatically uploaded. Certified collections are uploaded into the rh-certified
repository. Validated collections are uploaded into the validated
repository.
You can change to default configuration by using two variables:
-
automationhub_seed_collections
is a boolean that defines whether or not preloading is enabled. -
automationhub_collection_seed_repository
. A variable that enables you to specify the type of content to upload when it is set totrue
. Possible values arecertified
orvalidated
. If missing both content sets will be uploaded.
1.4.2. Installing validated content using the tarball
If you are not using the bundle installer, you can use a standalone tarball, ansible-validated-content-bundle-1.tar.gz
. You can also use this standalone tarball later to update validated contents in any environment, when a newer tarball becomes available, without having to re-run the bundle installer.
Prerequisites
You require the following variables to run the playbook.
Name | Description |
---|---|
| Your administration password. |
| The API token generated for your automation hub. |
|
For example, |
|
Boolean ( This must match the value used during automation hub deployment.
This variable is set to |
Procedure
- To obtain the tarball, navigate to the Red Hat Ansible Automation Platform download page and select Ansible Validated Content.
Upload the content and define the variables (this example uses
automationhub_api_token
):ansible-playbook collection_seed.yml -e automationhub_api_token=<api_token> -e automationhub_main_url=https://automationhub.example.com -e automationhub_require_content_approval=true
NoteUse either
automationhub_admin_password
orautomationhub_api_token
, not both.
When complete, the collections are visible in the validated collection section of private automation hub. Users can now view and download collections from your private automation hub.
Additional Resources
For more information on running ansible playbooks, see ansible-playbook.
Chapter 2. Managing collections in automation hub
As a content creator, you can use namespaces in automation hub to curate and manage collections for the following purposes:
- Create groups with permissions to curate namespaces and upload collections to private automation hub
- Add information and resources to the namespace to help end users of the collection in their automation tasks
- Upload collections to the namespace
- Review the namespace import logs to determine the success or failure of uploading the collection and its current approval status
For information on creating content, see the Red Hat Ansible Automation Platform Creator Guide.
2.1. Using namespaces to manage collections in automation hub
Namespaces are unique locations in automation hub to which you can upload and publish content collections. Access to namespaces in automation hub is governed by groups with permission to manage the content and related information that appears there.
You can use namespaces in automation hub to organize collections developed within your organization for internal distribution and use.
If you are working with namespaces, you must have a group that has permissions to create, edit and upload collections to namespaces. Collections uploaded to a namespace require administrative approval before you can publish them and make them available for use.
2.1.1. Creating a new group for content curators
You can create a new group in private automation hub designed to support content curation in your organization. This group can contribute internally developed collections for publication in private automation hub.
To help content developers create a namespace and upload their internally developed collections to private automation hub, you must first create and edit a group and assign the required permissions.
Prerequisites
- You have administrative permissions in private automation hub and can create groups.
Procedure
- Log in to your private automation hub.
- From the navigation panel, select → and click .
- Enter Content Engineering as a Name for the group in the modal and click . You have created the new group and the Groups page opens.
- On the Permissions tab, click .
- Under Namespaces, add permissions for Add Namespace, Upload to Namespace, and Change Namespace.
Click
.The new group is created with the permissions that you assigned. You can then add users to the group.
- Click the Users tab on the Groups page.
- Click .
- Select users and click .
2.1.2. Creating a namespace
You can create a namespace to organize collections that your content developers upload to automation hub. When creating a namespace, you can assign a group in automation hub as owners of that namespace.
Prerequisites
- You have Add Namespaces and Upload to Namespaces permissions.
Procedure
- Log in to your private automation hub.
- From the navigation panel, select → .
- Click namespace name. and enter a
- Assign a group of Namespace owners.
- Click .
Your content developers can now upload collections to your new namespace and allow users in groups assigned as owners to upload collections.
2.1.3. Adding additional information and resources to a namespace
You can add information and provide resources for your users to accompany collections included in the namespace. Add a logo and a description, and link users to your GitHub repository, issue tracker, or other online assets. You can also enter markdown text in the Edit resources tab to include more information. This is helpful to users who use your collection in their automation tasks.
Prerequisites
- You have Change Namespaces permissions.
Procedure
- Log in to your private automation hub.
- From the navigation panel, select → .
- Click the ⋮ and select Edit namespace. icon
- In the Edit details tab, enter information in the fields.
- Click the Edit resources tab to enter markdown in the text field.
- Click .
Your content developers can now upload collections to your new namespace, or allow users in groups assigned as owners to upload collections.
When you create a namespace, groups with permissions to upload to it can start adding their collections for approval. Collections in the namespace appear in the Published repository after approval.
2.1.4. Uploading collections to your namespaces
You can upload internally developed collections in tar.gz
file format to your private automation hub namespace for review and approval by an automation hub administrator. When approved, the collection moves to the Published content repository where automation hub users can view and download it.
Format your collection file name as follows: <my_namespace-my_collection-1.0.0.tar.gz>
Prerequisites
- You have a namespace to which you can upload the collection.
Procedure
- Log in to your private automation hub.
- From the navigation panel, select → and select a namespace.
- Click .
- Click New collection dialog. from the
- Select the collection to upload.
- Click .
The My Imports screen shows a summary of tests and notifies you if the collection uploaded successfully or if it failed.
2.1.5. Reviewing your namespace import logs
You can review the status of collections uploaded to your namespaces to evaluate success or failure of the process.
Imported collections information includes:
- Status
- completed or failed
- Approval status
- waiting for approval or approved
- Version
- the version of the uploaded collection
- Import log
- activities executed during the collection import
Prerequisites
- You have access to a namespace to which you can upload collections.
Procedure
- Log in to your private automation hub.
- From the navigation panel, select → .
- Select a namespace.
- Click the ⋮ and select My imports. icon
- Use the search field or locate an imported collection from the list.
- Click the imported collection.
- Review collection import details to determine the status of the collection in your namespace.
2.1.6. Deleting a namespace
You can delete unwanted namespaces to manage storage on your automation hub server. You must first ensure that the namespace does not contain a collection with dependencies.
Prerequisites
- The namespace you are deleting does not have a collection with dependencies.
- You have Delete namespace permissions.
Procedure
- Log in to your private automation hub.
- From the navigation panel, select → .
- Click the namespace to be deleted.
Click the ⋮, then click .
iconNoteIf the Deleting a collection on automation hub for information.
button is disabled, the namespace contains a collection with dependencies. Review the collections in this namespace, and delete any dependencies. See
The namespace that you deleted, as well as its associated collections, is now deleted and removed from the namespace list view.
2.2. Managing the publication process of internal collections in Automation Hub
Use automation hub to manage and publish content collections developed within your organization. You can upload and group collections in namespaces. They need administrative approval to appear in the Published content repository. After you publish a collection, your users can access and download it for use.
You can reject submitted collections that do not meet organizational certification criteria.
2.2.1. About Approval
You can manage uploaded collections in automation hub by using the Approval feature located in the navigation panel.
- Approval Dashboard
- By default, the Approval dashboard lists all collections with Needs Review status. You can check these for inclusion in your Published repository.
- Viewing collection details
- You can view more information about the collection by clicking the Version number.
- Filtering collections
- Filter collections by Namespace, Collection Name or Repository, to locate content and update its status.
2.2.2. Approving collections for internal publication
You can approve collections uploaded to individual namespaces for internal publication and use. All collections awaiting review are located under the Approval tab in the Staging repository.
Prerequisites
- You have Modify Ansible repo content permissions.
Procedure
From the navigation panel, select
→ .Collections requiring approval have the status Needs review.
- Select a collection to review.
- Click the Version to view the contents of the collection.
- Click to approve the collection.
Approved collections are moved to the Published repository where users can view and download them for use.
2.2.3. Rejecting collections uploaded for review
You can reject collections uploaded to individual namespaces. All collections awaiting review are located under the Approval tab in the Staging repository.
Collections requiring approval have the status Needs review. Click the Version to view the contents of the collection.
Prerequisites
- You have Modify Ansible repo content permissions.
Procedure
- From the navigation panel, select → .
- Locate the collection to review.
- Click to decline the collection.
Collections you decline for publication are moved to the Rejected repository.
2.3. Repository management with automation hub
As an automation hub administrator, you can create, edit, delete, and move automation content collections between repositories.
2.3.1. Types of repositories in automation hub
In automation hub you can publish collections to two types of repositories, depending on whether you want your collection to be verified:
- Staging repositories
-
Any user with permission to upload to a namespace can publish collections into these repositories. Collections in these repositories are not available in the search page. Instead, they are displayed on the approval dashboard for an administrator to verify. Staging repositories are marked with the
pipeline=staging
label. - Custom repositories
- Any user with write permissions on the repository can publish collections to these repositories. Custom repositories can be public where all users can see them, or private where only users with view permissions can see them. These repositories are not displayed on the approval dashboard. If the repository owner enables search, the collection can appear in search results.
By default, automation hub ships with one staging repository that is automatically used when a repository is not specified for uploading collections. Users can create new staging repositories during repository creation.
2.3.2. Approval pipeline for custom repositories in automation hub
In automation hub you can approve collections into any repository marked with the pipeline=approved
label. By default, automation hub includes one repository for approved content, but you have the option to add more from the repository creation screen. You cannot directly publish into a repository marked with the pipeline=approved
label. A collection must first go through a staging repository and be approved before being published into a 'pipleline=approved' repository.
- Auto approval
-
When auto approve is enabled, any collection you upload to a staging repository is automatically promoted to all of the repositories marked as
pipeline=approved
. - Approval required
When auto approve is disabled, the administrator can view the approval dashboard and see collections that have been uploaded into any of the staging repositories. Clicking
displays a list of approved repositories. From this list, the administrator can select one or more repositories to which the content should be promoted.If only one approved repository exists, the collection is automatically promoted into it and the administrator is not prompted to select a repository.
- Rejection
- Rejected collections are automatically placed into the rejected repository, which is pre-installed.
2.3.3. Role based access control to restrict access to custom repositories
Use Role Based Access Control (RBAC) to restrict user access to custom repositories by defining access permissions based on user roles. By default, users can view all public repositories in their automation hub, but they cannot modify a repository unless their role allows them access to do so. The same logic applies to other operations on the repository. For example, you can remove a user’s ability to download content from a custom repository by changing their role permissions. See Configuring user access for your private automation hub for information about managing user access in automation hub.
2.3.4. Creating a custom repository in automation hub
When you use Red Hat Ansible Automation Platform to create a repository, you can configure the repository to be private or hide it from search results.
Procedure
- Log in to automation hub.
- From the navigation panel, select → .
- Click .
- Enter a Repository name.
- In the Description field, describe the purpose of the repository.
To retain previous versions of your repository each time you make a change, select Retained number of versions. The number of retained versions can range anywhere between 0 and unlimited. To save all versions, leave this set to null.
NoteIf you have a problem with a change to your custom repository, you can revert to a different repository version that you have retained.
In the Pipeline field, select a pipeline for the repository. This option defines who can publish a collection into the repository.
- Staging
- Anyone is allowed to publish automation content into the repository.
- Approved
- Collections added to this repository are required to go through the approval process by way of the staging repository. When auto approve is enabled, any collection uploaded to a staging repository is automatically promoted to all of the approved repositories.
- None
- Any user with permissions on the repository can publish to the repository directly, and the repository is not part of the approval pipeline.
- Optional: To hide the repository from search results, select Hide from search. This option is selected by default.
- Optional: To make the repository private, select Make private. This hides the repository from anyone who does not have permissions to view the repository.
- To sync the content from a remote repository into this repository, select Remote and select the remote that contains the collections you want included in your custom repository. For more information, see Repository sync.
- Click .
Next steps
After the repository is created, the details page is displayed.
From here, you can provide access to your repository, review or add collections, and work with the saved versions of your custom repository.
2.3.5. Providing access to a custom automation hub repository
By default, private repositories and the automation content collections are hidden from all users in the system. Public repositories can be viewed by all users, but cannot be modified. Use this procedure to provide access to your custom repository.
Procedure
- Log in to private automation hub.
- From the navigation panel, select → .
- Locate your repository in the list and click the ⋮, then select Edit. icon
- Select the Access tab.
Select a group for Repository owners.
See Configuring user access for your private automation hub for information about implementing user access.
- Select the roles you want assigned to the selected group.
- Click .
2.3.6. Adding collections to an automation hub repository
After you create your repository, you can begin adding automation content collections to it.
Procedure
- From the navigation panel, select → .
- Locate your repository in the list and click the ⋮, then select Edit. icon
- Select the Collections version tab.
- Click and select the collections that you want to add to your repository.
- Click .
2.3.7. Revert to a different automation hub repository version
When automation content collections are added or removed from a repository, a new version is created. If a change to your repository causes a problem, you can revert to a previous version. Reverting is a safe operation and does not delete collections from the system, but rather, changes the content associated with the repository. The number of versions saved is defined in the Retained number of versions setting when a repository is created.
Procedure
- Log in to private automation hub.
- From the navigation panel, select → .
- Locate your repository in the list and click the ⋮, then select Edit. icon
- Locate the version you want to revert to and click the ⋮, and select Revert to this version. icon
- Click .
2.3.8. Managing remote configurations in automation hub
You can set up remote configurations to any server that is running automation hub. Remote configurations allow you to sync content to your custom repositories from an external collection source.
2.3.8.1. Creating a remote configuration in automation hub
You can use Red Hat Ansible Automation Platform to create a remote configuration to an external collection source. Then, you can sync the content from those collections to your custom repositories.
Procedure
- Log in to automation hub.
- From the navigation panel, select → .
- Click .
- Enter a Name for the remote configuration.
Enter the URL for the remote server, including the path for the specific repository.
NoteTo find the remote server URL and repository path, navigate to
→ , select your repository, and click .Configure the credentials to the remote server by entering a Token or Username and Password required to access the external collection.
NoteTo generate a token from the navigation panel, select
→ , click and copy the token that is loaded.- To access collections from console.redhat.com, enter the SSO URL to sign in to the identity provider (IdP).
Select or create a YAML requirements file to identify the collections and version ranges to synchronize with your custom repository. For example, to download only the kubernetes and AWS collection versions 5.0.0 or later the requirements file would look like this:
Collections: - name: community.kubernetes - name: community.aws version:”>=5.0.0”
NoteAll collection dependencies are downloaded during the Sync process.
Optional: To configure your remote further, use the options available under Advanced configuration:
- If there is a corporate proxy in place for your organization, enter a Proxy URL, Proxy Username and Proxy Password.
- Enable or disable transport layer security using the TLS validation checkbox.
- If digital certificates are required for authentication, enter a Client key and Client certificate.
- If you are using a self-signed SSL certificate for your server, enter the PEM encoded client certificate used for authentication in the CA certificate field.
- To accelerate the speed at which collections in this remote can be downloaded, specify the number of collections that can be downloaded in tandem in the Download concurrency field.
To limit the number of queries per second on this remote, specify a Rate Limit.
NoteSome servers can have a specific rate limit set, and if exceeded, synchronization fails.
2.3.8.2. Providing access to a remote configuration
After you create a remote configuration, you must provide access to it before anyone can use it.
Procedure
- Log in to private automation hub.
- From the navigation panel, select → .
- Locate your repository in the list, click the ⋮, and select Edit. icon
- Select the Access tab.
- Select a group for Repository owners. See Configuring user access for your private automation hub for information about implementing user access.
- Select the appropriate roles for the selected group.
- Click .
2.3.9. Synchronizing repositories in automation hub
You can distribute relevant automation content collections to your users by synchronizing repositories from one automation hub to another. To ensure you have the latest collection updates, synchronize your custom repository with the remote regularly.
Procedure
- Log in to automation hub.
- From the navigation panel, select → .
Locate your repository in the list and click Sync.
All collections in the configured remote are downloaded to your custom repository. To check the status of the collection sync, select
from the navigation panel.NoteTo limit repository synchronization to specific collections within a remote, you can identify specific collections to be pulled by using a requirements.yml file. See Create a remote for more information.
Additional resources
For more information about using requirements files, see Install multiple collections with a requirements file in the Using Ansible collections guide.
2.3.10. Exporting and importing collections in automation hub
Ansible automation hub stores automation content collections within repositories. These collections are versioned by the automation content creator. Many versions of the same collection can exist in the same or different repositories at the same time.
Collections are stored as .tar files that can be imported and exported. This storage format ensures that the collection you are importing to a new repository is the same one that was originally created and exported.
2.3.10.1. Exporting an automation content collection in automation hub
After collections are finalized, you can import them to a location where they can be distributed to others across your organization.
Procedure
- Log in to private automation hub.
- From the navigation panel, select Collections page displays all collections across all repositories. You can search for a specific collection. → . The
- Select the collection that you want to export. The collection details page opens.
- From the Install tab, select Download tarball. The .tar file is downloaded to your default browser downloads folder. You can now import it to the location of your choosing.
2.3.10.2. Importing an automation content collection in automation hub
As an automation content creator, you can import a collection to use in a custom repository. To use a collection in your custom repository, you must first import the collection into your namespace so the automation hub administrator can approve it.
Procedure
- Log in to automation hub.
- From the navigation panel, select Namespaces page displays all of the namespaces available. → . The
- Click .
- Click .
- Navigate to the collection tarball file, select the file and click .
Click
.The My Imports screen displays a summary of tests and notifies you if the collection upload is successful or has failed.
NoteIf the collection is not approved, it is not displayed in the published repository.
Additional resources
- See Approval pipeline for more information about collection and repository approvals.
Chapter 3. Manage containers in private automation hub
Learn the administrator workflows and processes for configuring private automation hub container registry and repositories.
3.1. Manage your private automation hub container registry
Manage container image repositories in your Ansible Automation Platform infrastructure by using the automation hub container registry. You can perform the following tasks with Automation hub:
- Control who can access individual container repositories
- Change tags on images
- View activity and image layers
- Provide additional information related to each container repository
3.1.1. Container registries
The automation hub container registry is used for storing and managing container images. When you have built or sourced a container image, you can push that container image to the registry portion of private automation hub to create a container repository.
Next steps
- Push a container image to the automation hub container registry.
- Create a group with access to the container repository in the registry.
- Add the new group to the container repository.
- Add a README to the container repository to provide users with information and relevant links.
3.2. Configuring user access for container repositories in private automation hub
To determine who can access and manage images in your Ansible Automation Platform, you must configure user access for container repositories in your private automation hub.
3.2.1. Container registry group permissions
You can control how users can interact with containers managed in private automation hub. Use the following list of permissions to create groups with the right privileges for your container registries.
Permission name | Description |
---|---|
Create new containers | Users can create new containers |
Change container namespace permissions | Users can change permissions on the container repository |
Change container | Users can change information on a container |
Change image tags | Users can modify image tags |
Pull private containers | Users can pull images from a private container |
Push to existing container | Users can push an image to an existing container |
View private containers | Users can view containers marked as private |
3.2.2. Creating a new group in private automation hub
You can create and assign permissions to a group in private automation hub that enables users to access specified features in the system. By default, the Admin group in the automation hub has all permissions assigned and is available on initial login. Use the credentials created when installing private automation hub.
For more information, see Creating a new group in private automation hub in the Getting started with automation hub guide.
3.2.3. Assigning permissions to groups
By default, new groups do not have any assigned permissions. You can assign permissions to groups in private automation hub that enable users to access specific features in the system.
You can add permissions when first creating a group or edit an existing group to add or remove permissions
For more information, see Assigning permissions to groups in the Getting started with automation hub guide.
Additional resources
- See Container registry group permissions to learn more about specific permissions.
3.2.4. Adding users to existing groups
You can add users to groups when you create a group. But, you can also manually add users to existing groups.
For more information, see Adding users to existing groups in the Getting started with automation hub guide.
3.3. Populating your private automation hub container registry
By default, private automation hub does not include container images. To populate your container registry, you must push a container image to it.
You must follow a specific workflow to populate your private automation hub container registry:
- Pull images from the Red Hat Ecosystem Catalog (registry.redhat.io)
- Tag them
- Push them to your private automation hub container registry
Image manifests and filesystem blobs were both originally served directly from registry.redhat.io
and registry.access.redhat.com
. As of 1 May 2023, filesystem blobs are served from quay.io
instead.
- Ensure that the Network ports and protocols listed in Table 5.10. Execution Environments (EE) are available to avoid problems pulling container images.
Make this change to any firewall configuration that specifically enables outbound connections to registry.redhat.io
or registry.access.redhat.com
.
Use the hostnames instead of IP addresses when configuring firewall rules.
After making this change you can continue to pull images from registry.redhat.io
and registry.access.redhat.com
. You do not require a quay.io
login, or need to interact with the quay.io
registry directly in any way to continue pulling Red Hat container images.
However, manifests, sometimes called “subscription allocations”, on the web-based Red Hat Subscription Management are no longer supported as of early 2024 with one exception: If a system is part of a closed network or “air gapped” system that does not receive its updates from Red Hat’s servers directly, manifests are supported until the release of Red Hat Satellite 6.16. Keep up to date with Red Hat Satellite Release Dates for the announcement for Red Hat Satellite 6.16’s release date announcement.
3.3.1. Pulling images for use in automation hub
Before you can push container images to your private automation hub, you must first pull them from an existing registry and tag them for use. The following example details how to pull an image from the Red Hat Ecosystem Catalog (registry.redhat.io).
As of early 2024, Red Hat no longer supports manifests or manifest lists on the Red Hat Subscription Management web platform, which has also been used interchangeably with “subscription allocations.” Red Hat also no longer supports most manifest functionality in Red Hat Satellite with one exception: * Red Hat Satellite users in closed network or “air gapped” networks that do not receive their updates directly from Red Hat servers can currently still use access.redhat.com
until the release of Red Hat Satellite 6.16.
New Red Hat accounts automatically use Simple Content Access for their subscription tooling. New Red Hat accounts and existing Satellite customers who can connect to Red Hat’s servers can find their manifests at console.redhat.com
.
Prerequisites
- You have permissions to pull images from registry.redhat.io.
- A Red Hat account with Simple Content Access enabled.
Procedure
- If you need to access your manifest for your container images log in to Red Hat Console.
- Click the three-dot menu for the manifest you need for your container images, and click .
Log in to Podman by using your registry.redhat.io credentials:
$ podman login registry.redhat.io
- Enter your username and password.
Pull a container image:
$ podman pull registry.redhat.io/<container_image_name>:<tag>
Verification
To verify that the image you recently pulled is contained in the list, take these steps:
List the images in local storage:
$ podman images
- Check the image name, and verify that the tag is correct.
Additional resources
- See Red Hat Ecosystem Catalog Help for information on registering and getting images.
- See Creating and managing manifests for a connected Satellite Server to learn more about the changes coming to Red Hat subscription tooling
3.3.2. Tagging images for use in automation hub
After you pull images from a registry, tag them for use in your private automation hub container registry.
Prerequisites
- You have pulled a container image from an external registry.
- You have the FQDN or IP address of the automation hub instance.
Procedure
Tag a local image with the automation hub container repository:
$ podman tag registry.redhat.io/<container_image_name>:<tag> <automation_hub_hostname>/<container_image_name>
Verification
List the images in local storage:
$ podman images
- Verify that the image you recently tagged with your automation hub information is contained in the list.
3.3.3. Pushing a container image to private automation hub
You can push tagged container images to private automation hub to create new containers and populate the container registry.
Prerequisites
- You have permissions to create new containers.
- You have the FQDN or IP address of the automation hub instance.
Procedure
Log in to Podman using your automation hub location and credentials:
$ podman login -u=<username> -p=<password> <automation_hub_url>
Push your container image to your automation hub container registry:
$ podman push <automation_hub_url>/<container_image_name>
Troubleshooting
The push
operation re-compresses image layers during the upload, which is not guaranteed to be reproducible and is client-implementation dependent. This may lead to image-layer digest changes and a failed push operation, resulting in Error: Copying this image requires changing layer representation, which is not possible (image is signed or the destination specifies a digest)
.
Verification
- Log in to your automation hub.
- Navigate to .
- Locate the container in the container repository list.
3.4. Setting up your container repository
When you set up your container repository, you must add a description, include a README, add groups that can access the repository, and tag images.
3.4.1. Prerequisites to setting up your container registry
- You are logged in to a private automation hub.
- You have permissions to change the repository.
3.4.2. Adding a README to your container repository
Add a README to your container repository to provide instructions to your users on how to work with the container. Automation hub container repositories support Markdown for creating a README. By default, the README is empty.
Prerequisites
- You have permissions to change containers.
Procedure
- Log in to automation hub.
- From the navigation panel, select → .
- Select your container repository.
- On the Detail tab, click .
- In the Raw Markdown text field, enter your README text in Markdown.
- Click when you are finished.
After you add a README, you can edit it at any time by clicking
and repeating steps 4 and 5.3.4.3. Providing access to your container repository
Provide access to your container repository for users who need to work with the images. Adding a group allows you to modify the permissions the group can have to the container repository. You can use this option to extend or restrict permissions based on what the group is assigned.
Prerequisites
- You have change container namespace permissions.
Procedure
- Log in to automation hub.
- From the navigation panel, select → .
- Select your container repository.
- From the Access tab, click .
- Select the group or groups to which you want to grant access and click .
- Select the roles that you want to add to this execution environment and click .
- Click .
3.4.4. Tagging container images
Tag images to add an additional name to images stored in your automation hub container repository. If no tag is added to an image, automation hub defaults to latest
for the name.
Prerequisites
- You have change image tags permissions.
Procedure
- From the navigation panel, select → .
- Select your container repository.
- Click the Images tab.
- Click the ⋮, and click . icon
- Add a new tag in the text field and click .
- Optional: Remove current tags by clicking on any of the tags for that image.
- Click .
Verification
- Click the Activity tab and review the latest changes.
3.4.5. Creating a credential in automation controller
To pull container images from a password or token-protected registry, you must create a credential in automation controller.
In earlier versions of Ansible Automation Platform, you were required to deploy a registry to store execution environment images. On Ansible Automation Platform 2.0 and later, the system operates as if you already have a container registry up and running. To store execution environment images, add the credentials of only your selected container registries.
Procedure
- Navigate to automation controller.
- From the navigation panel, select → .
- Click to create a new credential.
- Enter an authorization Name, Description, and Organization.
- Select the Credential Type.
- Enter the Authentication URL. This is the container registry address.
- Enter the Username and Password or Token required to log in to the container registry.
- Optional: To enable SSL verification, select Verify SSL.
- Click .
3.5. Pulling images from a container repository
Pull images from the automation hub container registry to make a copy to your local machine. Automation hub provides the podman pull
command for each latest
image in the container repository. You can copy and paste this command into your terminal, or use podman pull
to copy an image based on an image tag.
3.5.1. Pulling an image
You can pull images from the automation hub container registry to make a copy to your local machine.
Prerequisites
- You must have permission to view and pull from a private container repository.
Procedure
- If you are pulling container images from a password or token-protected registry, create a credential in automation controller before pulling the image.
- From the navigation panel, select → .
- Select your container repository.
- In the Pull this image entry, click .
- Paste and run the command in your terminal.
Verification
-
Run
podman images
to view images on your local machine.
3.5.2. Syncing images from a container repository
You can pull images from the automation hub container registry to sync an image to your local machine. To sync an image from a remote container registry, you must first configure a remote registry.
Prerequisites
You must have permission to view and pull from a private container repository.
Procedure
- From the navigation panel, select → .
- Add https://registry.redhat.io to the registry.
Add any required credentials to authenticate.
NoteSome container registries are aggressive with rate limiting. Set a rate limit under Advanced Options.
- From the navigation panel, select → .
- Click in the page header.
Select the registry you want to pull from. The Name field displays the name of the image displayed on your local registry.
NoteThe Upstream name field is the name of the image on the remote server. For example, if the upstream name is set to "alpine" and the Name field is "local/alpine", the alpine image is downloaded from the remote and renamed to "local/alpine".
- Set a list of tags to include or exclude. Syncing images with a large number of tags is time consuming and uses a lot of disk space.
Additional resources
- See Red Hat Container Registry Authentication for a list of registries.
- See the What is Podman? documentation for options to use when pulling images.
3.6. Working with signed containers
Automation execution environments are container images used by Ansible automation controller to run jobs. You can download this content to private automation hub, and publish it within your organization.
3.6.1. Deploying your system for container signing
Automation hub implements image signing to offer better security for the execution environment container images.
To deploy your system so that it is ready for container signing, create a signing script.
Installer looks for the script and key on the same server where installer is located.
Procedure
From a terminal, create a signing script, and pass the script path as an installer parameter.
Example:
#!/usr/bin/env bash # pulp_container SigningService will pass the next 4 variables to the script. MANIFEST_PATH=$1 FINGERPRINT="$PULP_SIGNING_KEY_FINGERPRINT" IMAGE_REFERENCE="$REFERENCE" SIGNATURE_PATH="$SIG_PATH" # Create container signature using skopeo skopeo standalone-sign \ $MANIFEST_PATH \ $IMAGE_REFERENCE \ $FINGERPRINT \ --output $SIGNATURE_PATH # Optionally pass the passphrase to the key if password protected. # --passphrase-file /path/to/key_password.txt # Check the exit status STATUS=$? if [ $STATUS -eq 0 ]; then echo {\"signature_path\": \"$SIGNATURE_PATH\"} else exit $STATUS fi
Review the Ansible Automation Platform installer inventory file for options for container signing that begin with
automationhub_*
.[all:vars] . . . automationhub_create_default_container_signing_service = True automationhub_container_signing_service_key = /absolute/path/to/key/to/sign automationhub_container_signing_service_script = /absolute/path/to/script/that/signs
- Once installation is complete, navigate to your automation hub.
- From the navigation panel, select .
- Ensure that you have a key titled container-default, or container-anyname.
The container-default
service is created by the Ansible Automation Platform installer.
3.6.2. Adding containers remotely to automation hub
You can add containers remotely to automation hub in one of the following two ways:
- Create Remotes
- Execution Environment
Procedure
- Log in to automation hub.
- From the navigation panel, select → .
Click
.- In the Name field, enter the name of the registry where the container resides.
- In the URL field, enter the URL of the registry where the container resides.
- In the Username field, enter the username if necessary.
- In the Password field, enter the password if necessary.
- Click .
3.6.3. Adding an execution environment
Automation execution environments are container images that make it possible to incorporate system-level dependencies and collection-based content. Each execution environment allows you to have a customized image to run jobs, and each of them contain only what you need when running the job.
Procedure
- From the navigation panel, select → .
- Click .
- Enter the name of the execution environment.
- Optional: Enter the upstream name.
- Under Registry, select the name of the registry from the drop-down menu.
- Enter tags in the Add tag(s) to include field. If the field is blank, all the tags are passed. You must specify which repository specific tags to pass.
The remaining fields are optional:
- Currently included tags
- Add tag(s) to exclude
- Currently excluded tag(s)
- Description
- Click .
- Synchronize the image.
3.6.4. Pushing container images from your local environment
Use the following procedure to sign images on a local system and push those signed images to the automation hub registry.
Procedure
From a terminal, log in to Podman, or any container client currently in use:
> podman pull <container-name>
After the image is pulled, add tags (for example: latest, rc, beta, or version numbers, such as 1.0; 2.3, and so on):
> podman tag <container-name> <server-address>/<container-name>:<tag name>
Sign the image after changes have been made, and push it back up to the automation hub registry:
> podman push <server-address>/<container-name>:<tag name> --tls-verify=false --sign-by <reference to the gpg key on your local>
If the image is not signed, it can only be pushed with any current signature embedded. Alternatively, you can use the following script to push the image without signing it:
> podman push <server-address>/<container-name>:<tag name> --tls-verify=false
- Once the image has been pushed, navigate to your automation hub.
- From the navigation panel, select → .
- To display the new execution environment, click the Refresh icon.
- Click the name of the image to view your pushed image.
Troubleshooting
The details page in automation hub indicates whether or not an image has been signed. If the details page indicates that an image is Unsigned, you can sign the image from automation hub using the following steps:
- Click the image name to navigate to the details page.
Click the ⋮. Three options are available:
icon- Use in Controller
- Delete
- Sign
- Click Sign from the drop-down menu.
The signing service signs the image. After the image is signed, the status changes to "signed".
3.6.5. Policies with signed images
Policies can be used by podman or other image clients to ensure the validity of the image by assigning specific policies to that signature.
3.6.6. Using podman to ensure an image is signed by a specific signature
When ensuring a signature is signed by specific signatures, the signature must be on your local environment.
Procedure
- From the navigation panel, select .
- Click the ⋮ next to the signature that you are using. icon
- Select Download key from the drop-down menu. A new window opens.
- In the Name field, enter the name of the key.
- Click .
3.6.7. Configuring the client to verify signatures
To ensure a container image pulled from the remote registry is properly signed, you must first configure the image with the proper public key in a policy file.
Prerequisites
- The client must have sudo privileges configured to verify signatures.
Procedure
Open your terminal and use the following command:
> sudo <name of editor> /etc/containers/policy.json
The file that is displayed is similar to this:
{ "default": [{"type": "reject"}], "transports": { "docker": { "quay.io": [{"type": "insecureAcceptAnything"}], "docker.io": [{"type": "insecureAcceptAnything"}], "<server-address>": [ { "type": "signedBy", "keyType": "GPGKeys", "keyPath": "/tmp/containersig.txt" }] } } }
This file shows that neither
quay.io
, ordocker.io
will perform the verification, because the type isinsecureAcceptAnything
which overrides the default type ofreject
. However,<server-address>
will perform the verification, because the parametertype
is set to"signedBy"
.NoteThe only
keyType
currently supported is GPG keys.Under the
<server-address>
entry, modify thekeyPath
<1> to include the name of your key file.{ "default": [{"type": "reject"}], "transports": { "docker": { "quay.io": [{"type": "insecureAcceptAnything"}], "docker.io": [{"type": "insecureAcceptAnything"}], "<server-address>": [{ "type": "signedBy", "keyType": "GPGKeys", "keyPath": "/tmp/<key file name>", "signedIdentity": { "type": "matchExact" } }] } } }
- Save and close the file.
Verification
- Pull the file using Podman, or your client of choice:
> podman pull <server-address>/<container-name>:<tag name> --tls-verify=false
This response verifies the image has been signed with no errors. If the image is not signed, the command fails.
Additional resources
- For more information about policy.json, see documentation for containers-policy.json.
3.7. Deleting a container repository
Delete a container repository from your private automation hub to manage your disk space. You can delete repositories from the Red Hat Ansible Automation Platform interface in the Container Repository list view.
Prerequisites
- You have permissions to manage repositories.
Procedure
- Navigate to automation hub.
- From the navigation panel, select → .
- On the container repository that you want to delete, click the ⋮, and click . icon
- When the confirmation message is displayed, click the checkbox and click .
Verification
- Return to the Execution Environments list view. If the container repository has been successfully deleted, the container repository is no longer on the list.