From 09ea2ca6884f91a2b893271ff497cb1440943353 Mon Sep 17 00:00:00 2001 From: Arthur Outhenin-Chalandre Date: Mon, 22 May 2023 02:28:21 +0200 Subject: [PATCH] project: fix arithmetic outside of jinja (#10106) This feature no longer works on Ansible 6 / ansible-core 2.13. We do not support these version officially yet but this will help for the future upgrade and may help some people running those inadvertently. Signed-off-by: Arthur Outhenin-Chalandre --- contrib/dind/roles/dind-cluster/tasks/main.yaml | 2 +- tests/cloud_playbooks/roles/packet-ci/tasks/create-vms.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/dind/roles/dind-cluster/tasks/main.yaml b/contrib/dind/roles/dind-cluster/tasks/main.yaml index 247a0a8e9..04609bb01 100644 --- a/contrib/dind/roles/dind-cluster/tasks/main.yaml +++ b/contrib/dind/roles/dind-cluster/tasks/main.yaml @@ -43,7 +43,7 @@ package: name: "{{ item }}" state: present - with_items: "{{ distro_extra_packages }} + [ 'rsyslog', 'openssh-server' ]" + with_items: "{{ distro_extra_packages + [ 'rsyslog', 'openssh-server' ] }}" - name: Start needed services service: diff --git a/tests/cloud_playbooks/roles/packet-ci/tasks/create-vms.yml b/tests/cloud_playbooks/roles/packet-ci/tasks/create-vms.yml index 77373151c..4f0a66844 100644 --- a/tests/cloud_playbooks/roles/packet-ci/tasks/create-vms.yml +++ b/tests/cloud_playbooks/roles/packet-ci/tasks/create-vms.yml @@ -12,7 +12,7 @@ - name: Template vm files for CI job set_fact: - vms_files: "{{ vms_files }} + [{{ lookup('ansible.builtin.template', 'vm.yml.j2') | from_yaml }}]" + vms_files: "{{ vms_files + [lookup('ansible.builtin.template', 'vm.yml.j2') | from_yaml] }}" vars: vms_files: [] loop: "{{ range(1, vm_count|int + 1, 1) | list }}"