SUSE: Fix version compare for OBS containers repository

Right now the OBS:Virtualization:containers repository is added to Leap
15 because the version comparison does not quite work. We need to use the
'version' test to properly compare distribution versions.

Change-Id: Ib2b8e8b41ad34daf387d2bfb0c7308c271570f21
This commit is contained in:
Markos Chandras 2018-10-25 14:36:47 +01:00
parent 7125cde0f6
commit 01c72cf58c
1 changed files with 1 additions and 1 deletions

View File

@ -20,7 +20,7 @@ lxc_hosts_external_repo:
# NOTE(hwoarang) Leap 15.X is newer than 42.X and it has all the necessary LXC packages so we don't need
# to use the OBS repository. As such we only add it if version is >= 42 so we can capture all the old Leap
# releases. Using the external repo can be removed once we drop support for 42.X
state: "{{ (ansible_distribution_major_version >= 42) | ternary ('present', 'absent') }}"
state: "{{ (ansible_distribution_version is version ('42.1', '>=')) | ternary ('present', 'absent') }}"
system_config_dir: "/etc/sysconfig"
systemd_utils_prefix: "/usr/lib/systemd"