From 4982ddc855157a7dcdc96fd36945a43cfd468ddb Mon Sep 17 00:00:00 2001 From: Andreas Zweili Date: Mon, 25 Oct 2021 13:12:07 +0200 Subject: [PATCH] add tasks to remove floppy drivers --- handlers/main.yml | 2 ++ tasks/main.yml | 11 +++++++++++ 2 files changed, 13 insertions(+) create mode 100644 handlers/main.yml diff --git a/handlers/main.yml b/handlers/main.yml new file mode 100644 index 0000000..f2aa675 --- /dev/null +++ b/handlers/main.yml @@ -0,0 +1,2 @@ +- name: reconfigure initramfs + command: dpkg-reconfigure -f noninteractive initramfs-tools diff --git a/tasks/main.yml b/tasks/main.yml index b230af5..8511991 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -2,3 +2,14 @@ apt: state: present name: "{{ packages }}" + +- name: "Blacklist the floppy driver module" + kernel_blacklist: + name: "floppy" + state: "present" + notify: "reconfigure initramfs" + +- name: "Unload the floppy driver module" + modprobe: + name: "floppy" + state: "absent"