From b99ff7f1c48bc8f6e766ef85344d114e6db95445 Mon Sep 17 00:00:00 2001 From: Riccardo Pittau Date: Tue, 21 Feb 2023 16:41:55 +0100 Subject: [PATCH] CI fixes and workarounds - Update shim-signed name for ubuntu jammy Latest update for the shim-signed package changed the name of the shimx64.efi signed file from shimx64.efi.signed to shimx64.efi.signed.latest - ansible lint temporary exclude rules - pin python-openstackclient to version <6.1.0 as higher versions are incompatible with openstacksdk < 0.103.0 and we pin it to version 0.99.0 because of bifrost incompatibility with ansible-collections-openstack version 2 or higher Change-Id: If4cfd9cc67b372d4fbbdc0a6ef928496cede1892 --- .ansible-lint | 10 ++++++++++ .../defaults/required_defaults_Debian_family.yml | 2 +- .../roles/bifrost-keystone-install/tasks/install.yml | 10 ++++++++-- 3 files changed, 19 insertions(+), 3 deletions(-) diff --git a/.ansible-lint b/.ansible-lint index 3e24aeb7d..895da3ece 100644 --- a/.ansible-lint +++ b/.ansible-lint @@ -2,6 +2,10 @@ skip_list: # FIXME: gradually fix and remove these exclusions: - fqcn[action] # Use FQCN for module actions - fqcn[action-core] # Use FQCN for builtin actions + - ignore-errors # Use failed_when and specify error conditions instead of using ignore_errors + - jinja[invalid] # Unrecognized type + - jinja[spacing] # Jinja2 spacing could be improved + - key-order[task] # You can improve the task key order - meta-no-info # meta/main.yml should contain relevant info - meta-no-tags # Tags must contain lowercase letters and digits only - name[casing] #All names should start with an uppercase letter @@ -9,11 +13,17 @@ skip_list: - name[play] # All plays should be named - name[template] # Jinja templates should only be at the end of 'name' - no-changed-when # Commands should not change things if nothing needs doing + - no-free-form # Avoid using free-form when calling module actions + - risky-file-permissions # File permissions unset or incorrect + - schema[meta] # Additional properties are not allowed + - schema[vars] # does not match any of the regexes + - var-naming # violates variable naming standards - yaml[colons] # Too many spaces after colon - yaml[comments] # Missing starting space in comment - yaml[empty-lines] # Too many blank lines - yaml[indentation] # Wrong indentation - yaml[line-length] # Line too long + - yaml[octal-values] # Forbidden implicit octal value - yaml[truthy] # Truthy value should be one of [false, true] # NOTE(dtantsur): the following rules should likely stay excluded: diff --git a/playbooks/roles/bifrost-ironic-install/defaults/required_defaults_Debian_family.yml b/playbooks/roles/bifrost-ironic-install/defaults/required_defaults_Debian_family.yml index 8c9392319..6fcd0c77c 100644 --- a/playbooks/roles/bifrost-ironic-install/defaults/required_defaults_Debian_family.yml +++ b/playbooks/roles/bifrost-ironic-install/defaults/required_defaults_Debian_family.yml @@ -9,7 +9,7 @@ efi_distro: "{{ ansible_facts['distribution'] | lower }}" grub_efi_package: grub-efi-amd64-signed grub_efi_binary: /usr/lib/grub/x86_64-efi-signed/grubx64.efi.signed shim_efi_package: shim-signed -shim_efi_binary: /usr/lib/shim/shimx64.efi.signed +shim_efi_binary: "/usr/lib/shim/shimx64.efi.signed{{ '.latest' if ansible_distribution_release == 'jammy' else '' }}" required_packages: - mariadb-server - python3-dev diff --git a/playbooks/roles/bifrost-keystone-install/tasks/install.yml b/playbooks/roles/bifrost-keystone-install/tasks/install.yml index 3a87e2189..e71a6ee8a 100644 --- a/playbooks/roles/bifrost-keystone-install/tasks/install.yml +++ b/playbooks/roles/bifrost-keystone-install/tasks/install.yml @@ -21,7 +21,7 @@ name: bifrost-nginx-install tasks_from: install -# NOTE(TheJulia) While we don't necessarilly require /opt/stack any longer +# NOTE(TheJulia) While we don't necessarily require /opt/stack any longer # and it should already be created by the Ansible setup, we will leave this # here for the time being. - name: "Ensure /opt/stack is present" @@ -39,11 +39,17 @@ vars: package: pymysql +- name: "Remove python-openstackclient from upper constraints" + lineinfile: + path: "{{ upper_constraints_file }}" + regexp: "^python\\-openstackclient" + state: absent + - name: "Install python-openstackclient" include_role: name: bifrost-pip-install vars: - package: python-openstackclient + package: "python-openstackclient<6.1.0" - name: "Install keystone" include_role: