mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 13:52:54 +00:00
docker_*: enable RHEL8 tests (#53313)
This commit is contained in:
25
test/integration/targets/setup_docker/tasks/RHEL8.yml
Normal file
25
test/integration/targets/setup_docker/tasks/RHEL8.yml
Normal file
@@ -0,0 +1,25 @@
|
||||
# The RHEL extras repository must be enabled to provide the container-selinux package.
|
||||
# See: https://docs.docker.com/engine/installation/linux/docker-ee/rhel/#install-using-the-repository
|
||||
|
||||
- name: Install Docker pre-reqs
|
||||
dnf:
|
||||
name:
|
||||
- dnf-utils
|
||||
- device-mapper-persistent-data
|
||||
- lvm2
|
||||
- libseccomp
|
||||
state: present
|
||||
|
||||
- name: Set-up repository
|
||||
command: dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
|
||||
|
||||
- name: Install docker
|
||||
dnf:
|
||||
name: docker-ce
|
||||
state: present
|
||||
|
||||
- name: Make sure the docker daemon is running (failure expected inside docker container)
|
||||
service:
|
||||
name: docker
|
||||
state: started
|
||||
ignore_errors: "{{ ansible_virtualization_type == 'docker' }}"
|
||||
@@ -2,13 +2,16 @@
|
||||
is_rhel: "{{ ansible_os_family == 'RedHat' and ansible_distribution != 'Fedora' }}"
|
||||
is_rhel6: "{{ is_rhel and ansible_distribution_major_version == '6' }}"
|
||||
is_rhel7: "{{ is_rhel and ansible_distribution_major_version == '7' }}"
|
||||
is_rhel8: "{{ is_rhel and ansible_distribution_major_version == '8' }}"
|
||||
block:
|
||||
- include_tasks: "{{ lookup('first_found', params) }}"
|
||||
vars:
|
||||
params:
|
||||
- '{{ ansible_distribution }}.yml'
|
||||
- '{{ ansible_os_family }}.yml'
|
||||
when: not is_rhel6
|
||||
when: not is_rhel6 and not is_rhel8
|
||||
- include_tasks: RHEL8.yml
|
||||
when: is_rhel8
|
||||
|
||||
- name: Install Python requirements
|
||||
vars:
|
||||
|
||||
Reference in New Issue
Block a user