Uploaded image for project: 'Red Hat OpenStack Services on OpenShift'
  1. Red Hat OpenStack Services on OpenShift
  2. OSPRH-20382

During edpm update run bootc variable are undefined.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • None
    • edpm-ansible
    • None
    • 1
    • False
    • Hide

      None

      Show
      None
    • False
    • ?
    • openstack-ansible-ee-container-1.0.16-1
    • None
    • EDPM Sprint 11, EDPM Sprint 12, EDPM Sprint 13
    • 3
    • Critical

      To Reproduce Steps to reproduce the behavior:

      1. run the edpm update update playbook:

       

      ---
      apiVersion: dataplane.openstack.org/v1beta1
      kind: OpenStackDataPlaneDeployment
      metadata:
        name: data-plane-update-kpatch-11
        namespace: openstack
      spec:
        nodeSets:
          - preprovisioned-nodeset
        servicesOverride:
          - update
       

      and then it fails with 

       

       

      TASK [osp.edpm.edpm_update : Update OS (bootc)] ********************************
      [ERROR]: Task failed: Error while evaluating conditional: object of type 'dict' has no attribute 'bootc'Task failed.
      Origin: /usr/share/ansible/collections/ansible_collections/osp/edpm/roles/edpm_update/tasks/main.yml:41:339     - ansible_local.bootc is not defined or not ansible_local.bootc
      40
      41 - name: Update OS (bootc)
           ^ column 3<<< caused by >>>Error while evaluating conditional: object of type 'dict' has no attribute 'bootc'
      Origin: /usr/share/ansible/collections/ansible_collections/osp/edpm/roles/edpm_update/tasks/main.yml:43:941 - name: Update OS (bootc)
      42   ansible.builtin.include_tasks: bootc.yml
      43   when: ansible_local.bootc
                 ^ column 9fatal: [compute-z2x1kmw1-0]: FAILED! => {"changed": false, "msg": "Task failed: Error while evaluating conditional: object of type 'dict' has no attribute 'bootc'"}
      fatal: [compute-z2x1kmw1-1]: FAILED! => {"changed": false, "msg": "Task failed: Error while evaluating conditional: object of type 'dict' has no attribute 'bootc'"}
      fatal: [compute-z2x1kmw1-2]: FAILED! => {"changed": false, "msg": "Task failed: Error while evaluating conditional: object of type 'dict' has no attribute 'bootc'"} 

       

       

       

      Expected behavior

      • No failure.

      Bug impact

      • Prevent the update of edpm nodes

      Known workaround

      • none

      Additional context

      • This patch recognize that that variable could be undefined as the bootstrap role was not run and added stronger conditional everywhere but there.

      Note that for update, the bootstrap code that set the required fact will not be run ... never so this fact will always be non defined.  Wouldn't it be better to load that task file if the bootc variable is empty during update ?

       

              jslagle@redhat.com James Slagle
              sathlang@redhat.com Sofer Athlan Guyot
              rhos-dfg-df
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Created:
                Updated: