Upgrade automation dashboard

This procedure applies when upgrading from automation dashboard versions before 0.1 (which did not include Redis) to the current version. This process involves running the installation program and updating your cluster configuration with new authentication requirements.

About this task

Note
For more information about recent updates to automation dashboard, see What’s new: Updates for automation dashboard.

Procedure

  1. Download the latest installation bundle from access.redhat.com. Navigate to Downloads > Red Hat Ansible Automation Platform Product Software.
  2. Extract the bundle to a new directory.
  3. Copy the inventory file from your previous installation directory to the new directory.
  4. Edit the inventory file to include the mandatory Redis configuration. You must add a [redis] group and define the redis_mode variable:
    Note

    The inventory file lines prefixed with + must be added when upgrading your automation dashboard.

     [database]
    host.example.com ansible_connection=local
    
    +[redis]
    +host.example.com ansible_connection=local
    +
     [all:vars]
    +redis_mode=standalone
    +
     postgresql_admin_username=postgres
     postgresql_admin_password=TODO
     # registry_username=
  5. Run the installation playbook from the new directory:
    ansible-galaxy collection install -r requirements.yml
    ansible-playbook -i inventory ansible.containerized_installer.dashboard_install --ask-become-pass
  6. Update your clusters.yaml file. You must add the refresh_token, client_id, and client_secret variables to your existing cluster configurations.
    Note

    For instructions on obtaining these values, see Integrating automation dashboard with your Ansible Automation Platform.

  7. Apply the updated configuration to the dashboard. You must copy the configuration file to the container's /tmp/ directory:
    podman cp clusters.yaml automation-dashboard-web:/tmp/
    podman exec -it automation-dashboard-web /venv/bin/python manage.py setclusters /tmp/clusters.yaml

Results

  1. Retrieve the current cluster configuration:
    podman exec -it automation-dashboard-web /venv/bin/python ./manage.py getclusters --decrypt
  2. Verify that the output displays the content from your clusters.yaml file, including the access_token, refresh_token, client_id, and client_secret fields.

Troubleshoot synchronization failures

If new jobs from Ansible Automation Platform do not synchronize to the automation dashboard after an upgrade, an interrupted synchronization job might be blocking the process. This occurs if the automation dashboard service stops or restarts while a synchronization task is active.

Before you begin

  • You have ssh access to the host machine.
  • You have access to the PostgreSQL database, including the database user password defined in your inventory file (variable dashboard_pg_password).

About this task

To resolve this issue, you must manually remove the stuck jobs from the database.

Procedure

  1. Connect to the automation dashboard database. You must replace <password> with your configured dashboard_pg_password. Replace 127.0.0.1 with database server address if external database is used.
    POSTGRES_PASSWORD=<password> psql -h 127.0.0.1 -p 5432 -U aapdashboard -d aapdashboard
  2. Identify jobs that are in a pending or running state:
    SELECT * FROM scheduler_syncjob WHERE status IN ('pending','waiting','running');
  3. Wait approximately one minute and run the command again. If the same job IDs appear in the output, these jobs are stuck.
  4. Delete the stuck jobs using their ID. Replace <id> with the ID returned in the previous step (for example, 20, 21):
    DELETE from scheduler_syncjob WHERE id IN (<id>);

Results

  • Refresh the automation dashboard to confirm that synchronization has resumed.