informatiquecdc.win_pending_reboot

win_pending_reboot - Checks if a Windows Server Needs a Reboot

Overview

  • This Ansible module checks three registry locations to see if a Windows Server is indicating that it needs a reboot.

Parameters

Parameter Choices/Defaults Description
skip_component_based_servicing
boolean
Choices:
  • no ←
  • yes
Choose whether to ignore reboots needed by the Component-Based Servicing feature.
skip_windows_update
boolean
Choices:
  • no ←
  • yes
Choose whether to ignore reboots needed by Windows Update.
skip_pending_file_rename
boolean
Choices:
  • no ←
  • yes
Choose whether to ignore reboots for pending file renames.
skip_pending_computer_rename
boolean
Choices:
  • no ←
  • yes
Choose whether to ignore reboots due to a pending computer rename.
skip_ccm_client_sdk
boolean
Choices:
  • no
  • yes ←
Choose whether to ignore reboots caused by the ConfigMgr client.

Examples

---
- hosts: localhost

  roles:
    - win_pending_reboot

  tasks:

    - name: Check if reboot is needed
      win_pending_reboot:
        skip_ccm_client_sdk: no
      register: test_pending_reboot_result

    - name: Reboot if needed
      win_reboot:
      when: test_pending_reboot_result.reboot_required

Return Values

Common return values are documented here. Here are the unique fields for this module:

Key Returned Description
component_based_servicing
boolean
success True when the Component-Based Servicing requested a reboot.

Example:
False
windows_update
boolean
success True when Windows Update requested a reboot.

Example:
False
pending_file_rename
boolean
success True when a pending file rename requested a reboot.

Example:
False
pending_computer_rename
boolean
success True when a pending computer rename requested a reboot.

Example:
False
ccm_client_sdk
boolean
success and skip_ccm_client_sdk = no True when the ConfigMgr client requested a reboot.

Example:
False
reboot_required
boolean
success True when the server needs a reboot.

Example:
True

Notes

Authors

  • Stéphane Bilqué (@sbilque)

License

This project is licensed under the MIT License.

See LICENSE for full details.

Informazioni sul progetto

Checks for pending Windows Reboots

Installa
ansible-galaxy install informatiquecdc.win_pending_reboot
Licenza
mit
Download
7.3k
Proprietario
Informatique CDC, subsidiary of Group Caisse des Dépôts is a key player in IT services and digital trust.