From 67c4025c55acbd36d97aa09b09600e5d92db7bc7 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Fri, 11 Jan 2019 01:13:36 +0100 Subject: [PATCH] call update-grub after changing config --- ansible/roles/base/handlers/main.yml | 3 +++ ansible/roles/base/tasks/07grub.yml | 1 + 2 files changed, 4 insertions(+) diff --git a/ansible/roles/base/handlers/main.yml b/ansible/roles/base/handlers/main.yml index a86fcde..920db82 100644 --- a/ansible/roles/base/handlers/main.yml +++ b/ansible/roles/base/handlers/main.yml @@ -8,3 +8,6 @@ service: name: openntpd state: restarted + +- name: update grub + command: update-grub diff --git a/ansible/roles/base/tasks/07grub.yml b/ansible/roles/base/tasks/07grub.yml index dbc9b32..d413ff6 100644 --- a/ansible/roles/base/tasks/07grub.yml +++ b/ansible/roles/base/tasks/07grub.yml @@ -5,3 +5,4 @@ regexp: '^#?GRUB_CMDLINE_LINUX=' line: 'GRUB_CMDLINE_LINUX="{% for opt,val in (install.kernel_cmdline | default({})).items() %}{{ opt }}={{ val }}{% if not loop.last %} {% endif %}{% endfor %}"' when: install is defined and install.kernel_cmdline is defined + notify: update grub -- 1.7.10.4