From e0b5c3022c3ad5abf03d5ed36da326e79249c2e1 Mon Sep 17 00:00:00 2001 From: Mark Turner Date: Mon, 3 Oct 2022 12:39:48 -0400 Subject: [PATCH] correct clevis askpass unit conditional (#81) --- tasks/main-clevis.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tasks/main-clevis.yml b/tasks/main-clevis.yml index a9ad9c2..20a8708 100644 --- a/tasks/main-clevis.yml +++ b/tasks/main-clevis.yml @@ -4,13 +4,14 @@ name: "{{ __nbde_client_packages }}" state: present +- name: Get services + service_facts: + - name: Enable clevis askpass unit service: name: clevis-luks-askpass.path enabled: yes - when: ansible_distribution != "RedHat" or - (not ansible_distribution_version is version("8.2", "==") and - not ansible_distribution_version is version("8.3", "==")) + when: ansible_facts.services['clevis-luks-askpass.service'] is defined - name: Generate nbde_client dracut config template: