3bd4c2a607
This playbook runs on hosts before deployment to be sure we don't have any conflicting services running and systems are in expected state. DocImpact Change-Id: If5f288b7fbdf269697ca834da4eb969b61683ca0 Partially-implements: blueprint precheck-tasks
14 lines
608 B
YAML
14 lines
608 B
YAML
---
|
|
- name: Checking that libvirt is not running
|
|
stat: path=/var/run/libvirt/libvirt-sock
|
|
register: result
|
|
failed_when: result.stat.exists
|
|
when: inventory_hostname in groups['compute']
|
|
|
|
- name: Checking Docker version
|
|
command: docker version
|
|
register: result
|
|
failed_when: result | failed
|
|
or (result.stdout | from_yaml).Server.Version | regex_replace('(\\d+\\.\\d+\\.\\d+).*', '\\1') | version_compare(docker_version_min, '<')
|
|
or (result.stdout | from_yaml).Server.Version | regex_replace('(\\d+\\.\\d+\\.\\d+).*', '\\1') | version_compare(docker_version_max, '>')
|