mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-06-15 12:27:38 +00:00
[PR #12281/b2a8fbe9 backport][stable-13] integration tests: remove test setup for Ubuntu <16.04 (#12283)
filesystem: remove test setup for Ubuntu <16.04 (#12281)
* filesystem: remove test setup for Ubuntu <16.04
* more Ubuntu 16.04 refs
* and more old Ubuntu refs in tests
* and yet more truisms in tests conditionals
(cherry picked from commit b2a8fbe9c7)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
parent
c18d643dd2
commit
4ad4642bb8
8 changed files with 11 additions and 37 deletions
|
|
@ -13,7 +13,6 @@
|
|||
when:
|
||||
- ansible_facts.system != 'FreeBSD'
|
||||
- ansible_facts.distribution != 'MacOSX'
|
||||
- ansible_facts.distribution != 'Ubuntu' or ansible_facts.distribution_version is version('18', '>=')
|
||||
|
||||
- block:
|
||||
- name: Install rust (containing cargo)
|
||||
|
|
@ -23,7 +22,7 @@
|
|||
- set_fact:
|
||||
has_cargo: true
|
||||
when:
|
||||
- ansible_facts.system == 'FreeBSD' and ansible_facts.distribution_version is version('13.0', '>')
|
||||
- ansible_facts.system == 'FreeBSD'
|
||||
|
||||
- block:
|
||||
- name: Download rustup
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@
|
|||
# /etc/init/ureadahead.conf to /etc/init/ureadahead.conf.distrib
|
||||
# https://bugs.launchpad.net/ubuntu/+source/ureadahead/+bug/997838
|
||||
when:
|
||||
- not (ansible_facts.distribution == "Ubuntu" and ansible_facts.distribution_major_version|int == 14)
|
||||
- not (ansible_facts.os_family == "Suse")
|
||||
- not (ansible_facts.distribution == 'Archlinux') # TODO: package seems to be broken, cannot be downloaded from mirrors?
|
||||
- not (ansible_facts.distribution == 'Alpine') # TODO: not sure what's wrong here, the module doesn't return what the tests expect
|
||||
|
|
|
|||
|
|
@ -32,7 +32,6 @@
|
|||
state: present
|
||||
when:
|
||||
- ansible_facts.os_family != 'Suse'
|
||||
- not (ansible_facts.distribution == 'Ubuntu' and ansible_facts.distribution_version is version('16.04', '<='))
|
||||
- ansible_facts.system != "FreeBSD"
|
||||
- not (ansible_facts.os_family == "RedHat" and ansible_facts.distribution_major_version is version('8', '>='))
|
||||
- ansible_facts.os_family != 'Archlinux' # TODO
|
||||
|
|
@ -58,14 +57,6 @@
|
|||
when:
|
||||
- ansible_facts.distribution == 'Alpine'
|
||||
|
||||
- name: "Install btrfs tools (Ubuntu <= 16.04)"
|
||||
ansible.builtin.package:
|
||||
name: btrfs-tools
|
||||
state: present
|
||||
when:
|
||||
- ansible_facts.distribution == 'Ubuntu'
|
||||
- ansible_facts.distribution_version is version('16.04', '<=')
|
||||
|
||||
- name: "Install btrfs progs (OpenSuse)"
|
||||
ansible.builtin.package:
|
||||
name:
|
||||
|
|
@ -114,7 +105,6 @@
|
|||
- name: "Install f2fs tools and get version"
|
||||
when:
|
||||
- ansible_facts.os_family != 'RedHat' or ansible_facts.distribution == 'Fedora'
|
||||
- ansible_facts.distribution != 'Ubuntu' or ansible_facts.distribution_version is version('16.04', '>=')
|
||||
- ansible_facts.system != "FreeBSD"
|
||||
block:
|
||||
- name: "Install f2fs tools"
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@
|
|||
become: true
|
||||
|
||||
# executable override
|
||||
|
||||
- name: Test executable override
|
||||
flatpak:
|
||||
name: com.dummy.App1
|
||||
|
|
@ -59,6 +58,4 @@
|
|||
command: >-
|
||||
pkill -f -- '{{ remote_tmp_dir }}/serve.py'
|
||||
|
||||
when: |
|
||||
ansible_facts.distribution == 'Fedora' or
|
||||
ansible_facts.distribution == 'Ubuntu' and not ansible_facts.distribution_major_version | int < 16
|
||||
when: ansible_facts.distribution in ['Fedora', 'Ubuntu']
|
||||
|
|
|
|||
|
|
@ -45,6 +45,4 @@
|
|||
vars:
|
||||
method: system
|
||||
|
||||
when: |
|
||||
ansible_facts.distribution == 'Fedora' or
|
||||
ansible_facts.distribution == 'Ubuntu' and not ansible_facts.distribution_major_version | int < 16
|
||||
when: ansible_facts.distribution in ['Fedora', 'Ubuntu']
|
||||
|
|
|
|||
|
|
@ -50,12 +50,7 @@ redis_module: redis
|
|||
|
||||
redis_password: PASS
|
||||
|
||||
old_redis: >-
|
||||
{{
|
||||
(ansible_facts.distribution == 'CentOS' and ansible_facts.distribution_major_version|int <= 7) or
|
||||
(ansible_facts.distribution == 'Ubuntu' and ansible_facts.distribution_major_version|int <= 18) or
|
||||
(ansible_facts.os_family == 'FreeBSD' and ansible_facts.distribution_major_version|int <= 12)
|
||||
}}
|
||||
old_redis: false
|
||||
|
||||
# Master
|
||||
master_port: 6379
|
||||
|
|
|
|||
|
|
@ -95,24 +95,24 @@
|
|||
- '"-d 0" in shutdown_result_minus["shutdown_command"]'
|
||||
when: ansible_facts.system == 'VMKernel'
|
||||
|
||||
- name: Ensure that systemd-sysv is absent in Ubuntu 18 and Debian
|
||||
- name: Ensure that systemd-sysv is absent in Ubuntu and Debian
|
||||
apt:
|
||||
name: sytemd-sysv
|
||||
state: absent
|
||||
when: (ansible_facts.distribution == 'Ubuntu' and ansible_facts.distribution_major_version is version('18', '>=')) or (ansible_facts.distribution == 'Debian')
|
||||
when: ansible_facts.distribution in ['Ubuntu', 'Debian']
|
||||
register: systemd_sysv_install
|
||||
|
||||
- name: Gather package facts
|
||||
package_facts:
|
||||
manager: apt
|
||||
when: (ansible_facts.distribution == 'Ubuntu' and ansible_facts.distribution_major_version is version('18', '>=')) or (ansible_facts.distribution == 'Debian')
|
||||
when: ansible_facts.distribution in ['Ubuntu', 'Debian']
|
||||
|
||||
- name: Execute shutdown if no systemd-sysv
|
||||
community.general.shutdown:
|
||||
register: shutdown_result
|
||||
check_mode: true
|
||||
when:
|
||||
- "(ansible_facts.distribution == 'Ubuntu' and ansible_facts.distribution_major_version is version('18', '>=')) or (ansible_facts.distribution == 'Debian')"
|
||||
- "ansible_facts.distribution in ['Ubuntu', 'Debian']"
|
||||
- '"systemd-sysv" not in ansible_facts.packages'
|
||||
|
||||
- name: Install systemd_sysv in case it has been removed in test
|
||||
|
|
@ -120,5 +120,5 @@
|
|||
name: systemd-sysv
|
||||
state: present
|
||||
when:
|
||||
- "(ansible_facts.distribution == 'Ubuntu' and ansible_facts.distribution_major_version is version('18', '>=')) or (ansible_facts.distribution == 'Debian')"
|
||||
- "ansible_facts.distribution in ['Ubuntu', 'Debian']"
|
||||
- "systemd_sysv_install is changed"
|
||||
|
|
|
|||
|
|
@ -18,9 +18,5 @@
|
|||
import_tasks: tests.yml
|
||||
|
||||
when: >
|
||||
(ansible_facts.distribution in ['RedHat', 'CentOS', 'ScientificLinux'] and ansible_facts.distribution_major_version is version('7', '>=')) or
|
||||
ansible_facts.distribution == 'Fedora' or
|
||||
(ansible_facts.distribution == 'Ubuntu' and ansible_facts.distribution_version is version('15.04', '>=')) or
|
||||
(ansible_facts.distribution == 'Debian' and ansible_facts.distribution_version is version('8', '>=')) or
|
||||
ansible_facts.os_family == 'Suse' or
|
||||
ansible_facts.distribution == 'Archlinux'
|
||||
ansible_facts.distribution in ['RedHat', 'CentOS', 'ScientificLinux', 'Fedora', 'Ubuntu', 'Debian', 'Archlinux'] or
|
||||
ansible_facts.os_family == 'Suse'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue