From 5977a4411921c1880ee023b945ac2cceb533749a Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Fri, 4 Oct 2019 16:49:17 +0100 Subject: [PATCH] Fix baremetal serial console autoenable If ironic_serial_console_autoenable is set to true, ironic compute node serial consoles are automatically enabled during kayobe overcloud post configure. However, the baremetal-compute-serial-console.yml playbook expects a variable called cmd to be defined, and set to 'enable' in order to enable serial consoles. This patch fixes the issue. We also add a conditional to only import the playbook when ironic is enabled in the overcloud. Change-Id: Ice26a113f9023b1a25a4af0552d07c5e95e64556 Story: 2006662 Task: 36924 --- ansible/baremetal-compute-serial-console-post-config.yml | 9 +++++++-- ...fix-baremetal-serial-autoenable-0ccfec017cf2ddbc.yaml | 7 +++++++ 2 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 releasenotes/notes/fix-baremetal-serial-autoenable-0ccfec017cf2ddbc.yaml diff --git a/ansible/baremetal-compute-serial-console-post-config.yml b/ansible/baremetal-compute-serial-console-post-config.yml index 0e2538cd7..0687114a6 100644 --- a/ansible/baremetal-compute-serial-console-post-config.yml +++ b/ansible/baremetal-compute-serial-console-post-config.yml @@ -1,6 +1,11 @@ --- -# This is a wrapper around baremetal-compute-serial-console which only runs the playbook when +# This is a wrapper around baremetal-compute-serial-console which only runs the +# playbook when Ironic is enabled in the overcloud and # ironic_serial_console_autoenable is set to true. - import_playbook: baremetal-compute-serial-console.yml - when: ironic_serial_console_autoenable | bool \ No newline at end of file + vars: + cmd: enable + when: + - kolla_enable_ironic | bool + - ironic_serial_console_autoenable | bool diff --git a/releasenotes/notes/fix-baremetal-serial-autoenable-0ccfec017cf2ddbc.yaml b/releasenotes/notes/fix-baremetal-serial-autoenable-0ccfec017cf2ddbc.yaml new file mode 100644 index 000000000..0a629e1a2 --- /dev/null +++ b/releasenotes/notes/fix-baremetal-serial-autoenable-0ccfec017cf2ddbc.yaml @@ -0,0 +1,7 @@ +--- +fixes: + - | + Fixes an issue with ``kayobe overcloud post configure`` when Ironic is + disabled, but ``ironic_serial_console_autoenable`` is set to ``true``. + See `story 2006662 `__ + for details.