mirror of
https://github.com/nicolabs/ansible-role-grub.git
synced 2025-09-07 05:09:56 +02:00
Made grub_timeout and grub_recordfail_timeout optional
This commit is contained in:
parent
04777093a3
commit
52cadaa0ec
|
@ -1,9 +1,9 @@
|
|||
---
|
||||
# defaults file for grub
|
||||
|
||||
grub_timeout: 5
|
||||
#grub_timeout: 5
|
||||
|
||||
grub_recordfail_timeout: "{{ grub_timeout }}"
|
||||
#grub_recordfail_timeout: "{{ grub_timeout }}"
|
||||
|
||||
# Add options here, for example:
|
||||
# grub_options:
|
||||
|
|
|
@ -3,18 +3,18 @@
|
|||
- name: test if grub_timeout is set correctly
|
||||
ansible.builtin.assert:
|
||||
that:
|
||||
- grub_timeout is defined
|
||||
- grub_timeout is number
|
||||
- grub_timeout >= 0
|
||||
quiet: yes
|
||||
when: grub_timeout is defined
|
||||
|
||||
- name: test if grub_recordfail_timeout is set correctly
|
||||
ansible.builtin.assert:
|
||||
that:
|
||||
- grub_recordfail_timeout is defined
|
||||
- grub_recordfail_timeout is number
|
||||
- grub_recordfail_timeout >= 0
|
||||
quiet: yes
|
||||
when: grub_timeout is defined and grub_recordfail_timeout is defined
|
||||
|
||||
- name: test if grub_options is set correctly
|
||||
ansible.builtin.assert:
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
line: GRUB_TIMEOUT={{ grub_timeout }}
|
||||
create: yes
|
||||
mode: "0664"
|
||||
when: grub_timeout is defined
|
||||
notify:
|
||||
- update grub
|
||||
|
||||
|
@ -26,6 +27,7 @@
|
|||
line: GRUB_RECORDFAIL_TIMEOUT={{ grub_recordfail_timeout }}
|
||||
create: yes
|
||||
mode: "0664"
|
||||
when: grub_recordfail_timeout is defined
|
||||
notify:
|
||||
- update grub
|
||||
|
||||
|
|
Loading…
Reference in a new issue