ceph-ansible/roles/ceph-container-engine/tasks/pre_requisites/prerequisites.yml

42 lines
1012 B
YAML

---
- name: include specific variables
include_vars: "{{ item }}"
with_first_found:
- "{{ ansible_distribution }}-{{ ansible_distribution_major_version }}.yml"
- "{{ ansible_os_family }}.yml"
- name: debian based systems tasks
include_tasks: debian_prerequisites.yml
when:
- ansible_os_family == 'Debian'
tags: with_pkg
# ensure extras enabled for docker
- name: enable extras on centos
yum_repository:
name: extras
state: present
enabled: yes
when:
- ansible_distribution == 'CentOS'
- ceph_docker_enable_centos_extra_repo | bool
tags:
with_pkg
- name: install container and lvm2 packages
package:
name: ['{{ container_package_name }}', '{{ container_binding_name }}', 'lvm2']
update_cache: true
register: result
until: result is succeeded
tags: with_pkg
- name: start container service
service:
name: '{{ container_service_name }}'
state: started
enabled: yes
tags:
with_pkg
when: container_service_name == 'docker'