Este contenido no está disponible en el idioma seleccionado.

Chapter 2. Configuring Red Hat Automation Hub as the primary source for content


You can define Red Hat Automation Hub as the default source for content in the ansible.cfg configuration file.

Prerequisites

  • Obtain the API token for the Automation Hub server. See Creating the Automation Hub API token for more information.

Procedure

  1. Add the server_list option under the [galaxy] section and provide one or more server names.
  2. Create a new section for each server name:

    [galaxy_server.<server_name>]
  3. Set the url option if necessary. The community Ansible Galaxy does not require an auth_url.
  4. Set the auth_url option for each server name.
  5. Set the API token for the Automation Hub server.

The following ansible.cfg example shows how to configure multiple servers in prioritized order, with Automation Hub configured as your primary source and an Ansible Galaxy server as a secondary source:

ansible.cfg

[galaxy]
server_list = automation_hub, my_org_hub

[galaxy_server.automation_hub]
url=https://cloud.redhat.com/api/automation-hub/ 
1

auth_url=https://sso.redhat.com/auth/realms/redhat-external/protocol/openid-connect/token

token=my_ah_token

[galaxy_server.my_org_hub]
url=https://automation.my_org/
username=my_user
password=my_pass

1
A trailing slash / must follow the server URL.

You have now configured Automation Hub as your default server and can proceed to download and install supported collections.

For more information on server list configuration options and using Ansible Galaxy as an Ansible content source, see the Ansible Galaxy User Guide.

Red Hat logoGithubredditYoutubeTwitter

Aprender

Pruebe, compre y venda

Comunidades

Acerca de la documentación de Red Hat

Ayudamos a los usuarios de Red Hat a innovar y alcanzar sus objetivos con nuestros productos y servicios con contenido en el que pueden confiar. Explore nuestras recientes actualizaciones.

Hacer que el código abierto sea más inclusivo

Red Hat se compromete a reemplazar el lenguaje problemático en nuestro código, documentación y propiedades web. Para más detalles, consulte el Blog de Red Hat.

Acerca de Red Hat

Ofrecemos soluciones reforzadas que facilitan a las empresas trabajar en plataformas y entornos, desde el centro de datos central hasta el perímetro de la red.

Theme

© 2026 Red Hat
Volver arriba