Upgrade the Ansible Automation Platform Operator

To upgrade to the latest version of Ansible Automation Platform Operator on OpenShift Container Platform, you can use the following procedure:

Before you begin

  1. For existing deployments only: You must deploy your automation controller and automation hub instances to the same, single namespace before upgrading. For more information see, Migrating from one namespace to another.
  2. Review the Backup and restore in an OpenShift environment section and backup your services:
    • AutomationControllerBackup
    • AutomationHubBackup
    • EDABackup
Important

Upgrading from Event-Driven Ansible 2.4 is not supported. If you are using Event-Driven Ansible 2.4 in production, contact Red Hat before you upgrade.

Procedure

  1. Log in to OpenShift Container Platform.
  2. Navigate to Operators > Installed Operators.
  3. Select the Ansible Automation Platform Operator installed on your project namespace.
  4. Select the Subscriptions tab.
  5. To upgrade to 2.6 change the channel to stable-2.6.
  6. This creates an InstallPlan for the user. Click Preview InstallPlan.
  7. Click Approve.
  8. Create a Custom Resource (CR) using the Ansible Automation Platform UI.
    Note

    The automation controller and automation hub UIs remain until all SSO configuration is supported in the platform gateway UI.

Results

You can confirm you have upgraded successfully by navigating to Operators > Installed Operators, here under Ansible Automation Platform you can verify the version number matches your target version.

Additionally, go to your Ansible Automation Platform Operator deployment and click All instances to verify if all instances upgraded correctly. All pods should display either a Running or Completed status, with no pods displaying an error status.

Create Ansible Automation Platform custom resources

After upgrading to the latest version of Ansible Automation Platform Operator on OpenShift Container Platform, you can create an Ansible Automation Platform custom resource (CR) that specifies the names of your existing deployments, in the same namespace.

About this task

The following example outlines the steps to deploy a new Event-Driven Ansible setup after upgrading to the latest version, with existing automation controller and automation hub deployments already in place.

The Appendix contains more examples of Ansible Automation Platform CRs for different deployments.

Procedure

  1. Log in to Red Hat OpenShift Container Platform.
  2. Navigate to Operators > Installed Operators.
  3. Select your Ansible Automation Platform Operator deployment.
  4. Select the Details tab.
  5. On the Ansible Automation Platform tile click Create instance.
  6. From the Create Ansible Automation Platform page enter a name for your instance in the Name field.
  7. Click YAML view and paste the following YAML (aap-existing-controller-and-hub-new-eda.yml):
    ---
    apiVersion: aap.ansible.com/v1alpha1
    kind: AnsibleAutomationPlatform
    metadata:
      name: myaap
    spec:
      # Development purposes only
      no_log: false
    
      controller:
        name: existing-controller #obtain name from controller CR
        disabled: false
    
      eda:
        disabled: false
    
      hub:
        name: existing-hub
        disabled: false
  8. Click Create.
    Note

    You can override the operator’s default image for automation controller, automation hub, or platform-resource app images by specifying the preferred image on the YAML spec. This enables upgrading a specific deployment, like a controller, without updating the operator.

    The recommended approach however, is to upgrade the operator and use the default image values.

Results

Navigate to your Ansible Automation Platform Operator deployment and click All instances to verify whether all instances have deployed correctly. You should see the Ansible Automation Platform instance and the deployed AutomationController, EDA, and AutomationHub instances here.

Alternatively, you can verify whether all instances deployed correctly by running oc get route in the command line.