jpmat296.upgrade_powershell

Ansible Role: Upgrade PowerShell

Ansible Galaxy
CI

This is an Ansible role designed to upgrade Windows PowerShell to version 5.1.

It uses Chocolatey to perform the upgrade and the Windows task scheduler to run the upgrade after a reboot. This ensures that the Ansible WinRM connection remains active during the upgrade process.

Compatibility

This role works with the following Windows versions:

  • Windows Server 2008 R2
  • Windows Server 2012
  • Windows Server 2012 R2

Before upgrading, it checks the current version of PowerShell. If the version is not 3.0, 4.0, or 5.0, no changes will be made.

For Windows 2016 and later versions, the role does nothing and does not produce an error.

Role Variables

You do not need to change any variables.

Dependencies

There are no dependencies.

Example Playbook

- hosts: windows_servers
  roles:
     - role: jpmat296.upgrade_powershell

License

This role is licensed under the BSD license.

Author Information

This role was created in 2020 by Jean-Pierre Matsumoto.

Informazioni sul progetto

Unattended PowerShell upgrade to version 5.1

Installa
ansible-galaxy install jpmat296.upgrade_powershell
Licenza
Unknown
Download
4.2k
Proprietario