Uploaded image for project: 'Satellite'
  1. Satellite
  2. SAT-30761

Ansible Callback does not work when using AAP 2.5

XMLWordPrintable

    • Enhancement
    • Hide
      .`ansible_tower_api_url` replaces `ansible_tower_fqdn` when configuring provisioning callback in Ansible Automation Platform

      The `ansible_tower_api_url` parameter has been introduced to ensure compatibility with Ansible Automation Platform{nbsp}2.5. The parameter defines the URL of your Ansible Automation Platform, including the required API path, for the purposes of configuring provisioning callback. It replaces the previously used `ansible_tower_fqdn` parameter.

      By default, the API path is set to `/api/controller/v2`. Note that if you are using Ansible Automation Platform{nbsp}2.4 or earlier, you must update the API path manually to `/api/v2`. To confirm which Ansible Automation Platform version you are using, check the API endpoints on your Ansible Automation Platform instance to verify the correct API path.
      Show
      .`ansible_tower_api_url` replaces `ansible_tower_fqdn` when configuring provisioning callback in Ansible Automation Platform The `ansible_tower_api_url` parameter has been introduced to ensure compatibility with Ansible Automation Platform{nbsp}2.5. The parameter defines the URL of your Ansible Automation Platform, including the required API path, for the purposes of configuring provisioning callback. It replaces the previously used `ansible_tower_fqdn` parameter. By default, the API path is set to `/api/controller/v2`. Note that if you are using Ansible Automation Platform{nbsp}2.4 or earlier, you must update the API path manually to `/api/v2`. To confirm which Ansible Automation Platform version you are using, check the API endpoints on your Ansible Automation Platform instance to verify the correct API path.
    • Done
    • Automated
    • Yes

      Description of problem:

      Our kickstart template calls the ansible_provisioning_callback snippet

      That ansible_provisioning_callback snippet further calls ansible_tower_callback_service and ansible_tower_callback_script snippets to setup the ansible callback on the deployed systems and perform the callback. 

       

      In both of those snippets, we have the `/api/v2/job_templates/` endpoint hardcoded for all satellite\foreman versions.

      This used to work fine till AAP 2.4. With AAP 2.5, a gateway was introduced and hence the `/api/v2` endpoints are now `/api/controller/v2` and this will result in failures to complete the ansible callback when end-user uses AAP 2.5. 

       

      How reproducible:

      Always

       

      Is this issue a regression from an earlier version:

      Regression due to change in the dependant product version and API end points

       

      Steps to Reproduce:

      1. Install AAP 2.5 and configure it for provisioning callback 

      2. Install Satellite 6.14\6.15\6.16 ( any of them ) and configure the same for ansible callback 

      3. Try a deployment from the satellite and trigger the ansible callback . 

       

      Actual behavior:

      The callback API fails with the following error.

       

      <!doctype html>
      <html lang="en">
      <head>
        <title>Not Found</title>
      </head>
      <body>
        <h1>Not Found</h1><p>The requested resource was not found on this server.</p>
      </body>
      </html>

       

      Expected behavior:

      No such errors. Satellite should be able to work with all supported versions of AAP 

      • Perhaps we can enforce a version validation via host params for AAP and in the template can have conditionals based on it to choose old or new endpoints.
      • Or, we can let users pass a host_param for the API endpoint itself and we document the use of the same in our guides. 

       

      Business Impact / Additional info:

      Unable to build systems and perform ansible callback, when using AAP 2.5 + Satellite 6 ( Blocker )

       

              rh-ee-nalfassi Nofar Alfassi
              rhn-support-saydas Sayan Das
              Gaurav Talreja Gaurav Talreja
              Aneta Šteflová Petrová Aneta Šteflová Petrová
              Votes:
              1 Vote for this issue
              Watchers:
              13 Start watching this issue

                Created:
                Updated:
                Resolved: