Skip to content
This repository was archived by the owner on Jul 21, 2023. It is now read-only.

Commit 0d05a8a

Browse files
committed
roles: don't build VDDK plugin for new nbdkit
In nbdkit from 1.2.4 the VDDK plugin is already prebuilt and does not need to be built separately. In fact we should not even try to build it as this will fail -- the SRPM is missing needed spec file. Signed-off-by: Tomáš Golembiovský <[email protected]>
1 parent 03a0743 commit 0d05a8a

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

tasks/install.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,29 @@
2929
- nbdkit
3030
- nbdkit-plugin-python2
3131

32+
- name: Register nbdkit version
33+
yum:
34+
list: nbdkit
35+
register: pkg_nbdkit
36+
37+
- set_fact:
38+
pkg_nbdkit: "{{ pkg_nbdkit.results | selectattr('yumstate', '==', 'installed') | first }}"
39+
40+
- debug: var=pkg_nbdkit
41+
3242
- include_tasks: "vddk-install.yml"
43+
44+
# With nbdkit before 1.2.4 we had to build our own version of VDDK plugin
3345
- include_tasks: "nbdkit-plugin-vddk-rpm.yml"
46+
when:
47+
- pkg_nbdkit.epoch == "0"
48+
- pkg_nbdkit.version is version_compare('1.2.4', '<')
49+
50+
# With nbdkit 1.2.4 and newer we just make sure the package is installed
51+
- name: Make sure VDDK plugin is installed
52+
yum:
53+
state: "{{ v2v_yum_check }}"
54+
name: nbdkit-plugin-vddk
3455

3556
- name: Install virt-v2v
3657
yum:

0 commit comments

Comments
 (0)