Skip to content

Commit

Permalink
Merge pull request #1209 from stackhpc/yoga-molly-guard
Browse files Browse the repository at this point in the history
yoga: Fix reboot hang on systems with molly-guard, add timeout variable
  • Loading branch information
markgoddard authored Aug 5, 2024
2 parents e25cc4c + 382f735 commit 9b9971d
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
12 changes: 12 additions & 0 deletions etc/kayobe/ansible/reboot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,19 @@
serial: "{{ lookup('env', 'ANSIBLE_SERIAL') | default(1, true) }}"
tags:
- reboot
vars:
reboot_timeout_s: "{{ 20 * 60 }}"
tasks:
- name: Reboot and wait
become: true
reboot:
reboot_timeout: "{{ reboot_timeout_s }}"
search_paths:
# Systems running molly-guard hang waiting for confirmation before rebooting without this.
- "/lib/molly-guard"
# Default list:
- "/sbin"
- "/bin"
- "/usr/sbin"
- "/usr/bin"
- "/usr/local/sbin"
18 changes: 18 additions & 0 deletions etc/kayobe/ansible/ubuntu-upgrade.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@
reboot:
reboot_timeout: "{{ reboot_timeout_s }}"
connect_timeout: 600
search_paths:
# Systems running molly-guard hang waiting for confirmation before rebooting without this.
- "/lib/molly-guard"
# Default list:
- "/sbin"
- "/bin"
- "/usr/sbin"
- "/usr/bin"
- "/usr/local/sbin"
become: true
when: file_status.stat.exists

Expand Down Expand Up @@ -101,6 +110,15 @@
reboot:
reboot_timeout: "{{ reboot_timeout_s }}"
connect_timeout: 600
search_paths:
# Systems running molly-guard hang waiting for confirmation before rebooting without this.
- "/lib/molly-guard"
# Default list:
- "/sbin"
- "/bin"
- "/usr/sbin"
- "/usr/bin"
- "/usr/local/sbin"
become: true

- name: Update distribution facts
Expand Down

0 comments on commit 9b9971d

Please sign in to comment.