Skip to content

Commit 7f6ca80

Browse files
authoredMar 14, 2024··
Upgrade ansible-core to 2.16.4 (#10984)
* upgrade ansible version Needed for with_first_found to work correctly: ansible/ansible#70772 fixed in 2.16 * Remove unused google cloud cloud_playbook * Fix dpkg_selection on non-existing packages Needed since ansible-core>2.16, see: ansible/ansible@f10d11b
1 parent 7f785a5 commit 7f6ca80

File tree

10 files changed

+10
-241
lines changed

10 files changed

+10
-241
lines changed
 

‎docs/ansible.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Based on the table below and the available python version for your ansible host
3232

3333
| Ansible Version | Python Version |
3434
|-----------------|----------------|
35-
| >= 2.15.5 | 3.9-3.11 |
35+
| >= 2.16.4 | 3.9-3.11 |
3636

3737
## Inventory
3838

‎meta/runtime.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
requires_ansible: '>=2.15.5'
2+
requires_ansible: '>=2.16.4'

‎playbooks/ansible_version.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
become: no
66
run_once: true
77
vars:
8-
minimal_ansible_version: 2.15.5 # 2.15 versions before 2.15.5 are known to be buggy for kubespray
8+
minimal_ansible_version: 2.16.4
99
maximal_ansible_version: 2.17.0
1010
tags: always
1111
tasks:

‎requirements.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
ansible==8.5.0
1+
ansible==9.3.0
22
cryptography==41.0.4
33
jinja2==3.1.2
44
jmespath==1.0.1
55
MarkupSafe==2.1.3
66
netaddr==0.9.0
77
pbr==5.11.1
8-
ruamel.yaml==0.17.35
8+
ruamel.yaml==0.18.5
99
ruamel.yaml.clib==0.2.8

‎roles/container-engine/docker/tasks/main.yml

+4
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,11 @@
9696
name: "{{ item }}"
9797
selection: install
9898
when: ansible_pkg_mgr == 'apt'
99+
register: ret
99100
changed_when: false
101+
failed_when:
102+
- ret is failed
103+
- ret.msg != ( "Failed to find package '" + item + "' to perform selection 'install'." )
100104
with_items:
101105
- "{{ containerd_package }}"
102106
- docker-ce

‎tests/Makefile

-22
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,6 @@ create-tf:
2222
delete-tf:
2323
./scripts/delete-tf.sh
2424

25-
create-gce: init-gce
26-
ansible-playbook cloud_playbooks/create-gce.yml -i local_inventory/hosts.cfg -c local \
27-
$(ANSIBLE_LOG_LEVEL) \
28-
-e @"files/${CI_JOB_NAME}.yml" \
29-
-e gce_credentials_file=$(HOME)/.ssh/gce.json \
30-
-e gce_project_id=$(GCE_PROJECT_ID) \
31-
-e gce_service_account_email=$(GCE_ACCOUNT) \
32-
-e inventory_path=$(INVENTORY) \
33-
-e test_id=$(TEST_ID) \
34-
-e preemptible=$(GCE_PREEMPTIBLE)
35-
36-
37-
delete-gce:
38-
ansible-playbook -i $(INVENTORY) cloud_playbooks/delete-gce.yml -c local \
39-
$(ANSIBLE_LOG_LEVEL) \
40-
-e @"files/${CI_JOB_NAME}.yml" \
41-
-e test_id=$(TEST_ID) \
42-
-e gce_project_id=$(GCE_PROJECT_ID) \
43-
-e gce_service_account_email=$(GCE_ACCOUNT) \
44-
-e gce_credentials_file=$(HOME)/.ssh/gce.json \
45-
-e inventory_path=$(INVENTORY)
46-
4725
create-do: init-do
4826
ansible-playbook cloud_playbooks/create-do.yml -i local_inventory/hosts.cfg -c local \
4927
${ANSIBLE_LOG_LEVEL} \

‎tests/cloud_playbooks/create-gce.yml

-81
This file was deleted.

‎tests/cloud_playbooks/delete-gce.yml

-50
This file was deleted.

‎tests/cloud_playbooks/upload-logs-gcs.yml

-82
This file was deleted.

‎tests/requirements.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
-r ../requirements.txt
2-
ansible-lint==6.20.3
2+
ansible-lint==6.22.2
33
apache-libcloud==3.8.0
44
ara[server]==1.7.0
55
dopy==0.3.7

0 commit comments

Comments
 (0)
Please sign in to comment.