kolla_action == config is broken with octavia_auto_configure

Bug #1987299 reported by Will Szumski
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
kolla-ansible
Fix Released
Undecided
Unassigned

Bug Description

Environment
~~~~~~~~~~

- release: stable/wallaby
- Host OS: CentOS 8 stream
- Containers: CentOS 8 Stream

Description
~~~~~~~~~~~~

I'm driving kolla-ansible with kayobe. I'm running the command:

  kayobe# kayobe overcloud service configuration generate \
        --node-config-dir /tmp/config-new

The command is failing on the task:

- Copying over octavia.conf

The error is:

- project_info is undefined

I believe the issue is that we are not running the tasks that collect the facts needed for the configuration generation to work. The tasks are contained within:

https://github.com/openstack/kolla-ansible/blob/63d72ea7e8b1418ccdaddd45b788ab98fb541c21/ansible/roles/octavia/tasks/get_resources_info.yml

We could include this file during the config action. This creates a dependency on the kolla_toolbox container, but given that you need a functional cloud to create these resources in the first place (so you can reference them in the config file), I guess that is reasonable. It does mean that you can't generate the config before deploying the containers (if you have enabled octavia with auto-configure). It is possible to workaround this by skipping the octavia role completely or by setting octavia_auto_configure to false and setting:

- octavia_amp_image_owner_id
- octavia_amp_boot_network_list
- octavia_amp_secgroup_list
- octavia_amp_flavor_id

Revision history for this message
Will Szumski (willjs) wrote :

The kolla-ansible equivalent would be kolla-ansible genconfig:

https://github.com/openstack/kolla-ansible/blob/63d72ea7e8b1418ccdaddd45b788ab98fb541c21/tools/kolla-ansible#L198

Which doesn't appear in the docs:

https://docs.openstack.org/kolla-ansible/latest/user/operating-kolla.html#kolla-ansible-cli

But is documented in the help of the command itself.

Changed in kolla-ansible:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (master)

Reviewed: https://review.opendev.org/c/openstack/kolla-ansible/+/853989
Committed: https://opendev.org/openstack/kolla-ansible/commit/2bf4d4db4e9e67e571e3baa5122d4cf0f3d57244
Submitter: "Zuul (22348)"
Branch: master

commit 2bf4d4db4e9e67e571e3baa5122d4cf0f3d57244
Author: Will Szumski <email address hidden>
Date: Mon Aug 22 14:59:02 2022 +0100

    Fix issue with genconfig and octavia_auto_configure

    Makes sure the facts required to generate octavia.conf are available
    when using genconfig.

    This change also ensures that the necessary tasks run when using Ansible
    check mode.

    Closes-Bug: #1987299
    Change-Id: Ib8fbee2d3abdcfd2eae0f9b3e9b69eeb0e3086e0

Changed in kolla-ansible:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla-ansible (stable/zed)

Fix proposed to branch: stable/zed
Review: https://review.opendev.org/c/openstack/kolla-ansible/+/870509

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla-ansible (stable/yoga)

Fix proposed to branch: stable/yoga
Review: https://review.opendev.org/c/openstack/kolla-ansible/+/870770

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla-ansible (stable/xena)

Fix proposed to branch: stable/xena
Review: https://review.opendev.org/c/openstack/kolla-ansible/+/870771

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla-ansible (stable/wallaby)

Fix proposed to branch: stable/wallaby
Review: https://review.opendev.org/c/openstack/kolla-ansible/+/870772

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (stable/yoga)

Reviewed: https://review.opendev.org/c/openstack/kolla-ansible/+/870770
Committed: https://opendev.org/openstack/kolla-ansible/commit/367afaca50a7f7ed470894c31f47608a51c2b49c
Submitter: "Zuul (22348)"
Branch: stable/yoga

commit 367afaca50a7f7ed470894c31f47608a51c2b49c
Author: Will Szumski <email address hidden>
Date: Mon Aug 22 14:59:02 2022 +0100

    Fix issue with genconfig and octavia_auto_configure

    Makes sure the facts required to generate octavia.conf are available
    when using genconfig.

    This change also ensures that the necessary tasks run when using Ansible
    check mode.

    Closes-Bug: #1987299
    Change-Id: Ib8fbee2d3abdcfd2eae0f9b3e9b69eeb0e3086e0
    (cherry picked from commit 2bf4d4db4e9e67e571e3baa5122d4cf0f3d57244)

tags: added: in-stable-yoga
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (stable/xena)

Reviewed: https://review.opendev.org/c/openstack/kolla-ansible/+/870771
Committed: https://opendev.org/openstack/kolla-ansible/commit/c7b30f4b9d795b30475d8cdf2323d84d036ba439
Submitter: "Zuul (22348)"
Branch: stable/xena

commit c7b30f4b9d795b30475d8cdf2323d84d036ba439
Author: Will Szumski <email address hidden>
Date: Mon Aug 22 14:59:02 2022 +0100

    Fix issue with genconfig and octavia_auto_configure

    Makes sure the facts required to generate octavia.conf are available
    when using genconfig.

    This change also ensures that the necessary tasks run when using Ansible
    check mode.

    Closes-Bug: #1987299
    Change-Id: Ib8fbee2d3abdcfd2eae0f9b3e9b69eeb0e3086e0
    (cherry picked from commit 2bf4d4db4e9e67e571e3baa5122d4cf0f3d57244)

tags: added: in-stable-xena
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (stable/wallaby)

Reviewed: https://review.opendev.org/c/openstack/kolla-ansible/+/870772
Committed: https://opendev.org/openstack/kolla-ansible/commit/8aba747af0d8e0962dd093fe9cc88dceddd18cbd
Submitter: "Zuul (22348)"
Branch: stable/wallaby

commit 8aba747af0d8e0962dd093fe9cc88dceddd18cbd
Author: Will Szumski <email address hidden>
Date: Mon Aug 22 14:59:02 2022 +0100

    Fix issue with genconfig and octavia_auto_configure

    Makes sure the facts required to generate octavia.conf are available
    when using genconfig.

    This change also ensures that the necessary tasks run when using Ansible
    check mode.

    Closes-Bug: #1987299
    Change-Id: Ib8fbee2d3abdcfd2eae0f9b3e9b69eeb0e3086e0
    (cherry picked from commit 2bf4d4db4e9e67e571e3baa5122d4cf0f3d57244)

tags: added: in-stable-wallaby
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (stable/zed)

Reviewed: https://review.opendev.org/c/openstack/kolla-ansible/+/870509
Committed: https://opendev.org/openstack/kolla-ansible/commit/a9ee32d79245f028841e8cc9500ee165e8a25f8e
Submitter: "Zuul (22348)"
Branch: stable/zed

commit a9ee32d79245f028841e8cc9500ee165e8a25f8e
Author: Will Szumski <email address hidden>
Date: Mon Aug 22 14:59:02 2022 +0100

    Fix issue with genconfig and octavia_auto_configure

    Makes sure the facts required to generate octavia.conf are available
    when using genconfig.

    This change also ensures that the necessary tasks run when using Ansible
    check mode.

    Closes-Bug: #1987299
    Change-Id: Ib8fbee2d3abdcfd2eae0f9b3e9b69eeb0e3086e0
    (cherry picked from commit 2bf4d4db4e9e67e571e3baa5122d4cf0f3d57244)

tags: added: in-stable-zed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible 13.8.0

This issue was fixed in the openstack/kolla-ansible 13.8.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible 14.8.0

This issue was fixed in the openstack/kolla-ansible 14.8.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible 15.1.0

This issue was fixed in the openstack/kolla-ansible 15.1.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible 16.0.0.0rc1

This issue was fixed in the openstack/kolla-ansible 16.0.0.0rc1 release candidate.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible wallaby-eol

This issue was fixed in the openstack/kolla-ansible wallaby-eol release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.