From 69d67b5533734b4d34100aeb10c146c3abf2150c Mon Sep 17 00:00:00 2001 From: Felix Fontein Date: Mon, 11 Dec 2023 23:17:06 +0100 Subject: [PATCH] Add requirements to two modules. --- plugins/modules/java_cert.py | 24 ++++++++++++++++++++++++ plugins/modules/ufw.py | 5 +++++ 2 files changed, 29 insertions(+) diff --git a/plugins/modules/java_cert.py b/plugins/modules/java_cert.py index 3f3e5aa014..2590144d61 100644 --- a/plugins/modules/java_cert.py +++ b/plugins/modules/java_cert.py @@ -99,6 +99,30 @@ options: choices: [ absent, present ] default: present requirements: [openssl, keytool] +installable_requirements: + - name: Java keytool + blocks: + - system: + - openjdk11-jre-headless + when: ansible_facts.os_family == 'Alpine' + - system: + - java-11-openjdk-headless + when: ansible_facts.os_family in ['RedHat', 'Suse'] + - system: + - jre11-openjdk-headless + when: ansible_facts.os_family == 'Archlinux' + - system: + - ca-certificates-java + when: ansible_facts.distribution == 'Debian' and ansible_facts.distribution_major_version | int < 12 + - system: + - ca-certificates-java + - openjdk-17-jre-headless + when: ansible_facts.os_family == 'Debian' + - name: OpenSSL + blocks: + - system: + - openssl + when: true author: - Adam Hamsik (@haad) ''' diff --git a/plugins/modules/ufw.py b/plugins/modules/ufw.py index 5d187793bd..3491d055ea 100644 --- a/plugins/modules/ufw.py +++ b/plugins/modules/ufw.py @@ -32,6 +32,11 @@ attributes: support: full diff_mode: support: none +installable_requirements: + - name: ufw firewall + blocks: + - system: + - ufw options: state: description: