feat: streamline the chocolatey install and removed windows system updates
This commit is contained in:
@@ -6,23 +6,6 @@
|
|||||||
ansible.builtin.debug:
|
ansible.builtin.debug:
|
||||||
msg: "OS: {{ ansible_os_name }}"
|
msg: "OS: {{ ansible_os_name }}"
|
||||||
|
|
||||||
- name: Ensure .NET Framework 4.8 requirement is satisfied for Chocolatey v2.0.0 and later
|
|
||||||
when: ansible_os_installation_type != "Server Core"
|
|
||||||
block:
|
|
||||||
- name: Install Chocolatey CLI
|
|
||||||
chocolatey.chocolatey.win_chocolatey:
|
|
||||||
name: chocolatey
|
|
||||||
state: present
|
|
||||||
version: 1.4.0
|
|
||||||
|
|
||||||
- name: Install Microsoft .NET Framework 4.8
|
|
||||||
chocolatey.chocolatey.win_chocolatey:
|
|
||||||
name: netfx-4.8
|
|
||||||
state: present
|
|
||||||
|
|
||||||
- name: Reboot the host to complete .NET Framework 4.8 install
|
|
||||||
ansible.windows.win_reboot:
|
|
||||||
|
|
||||||
- name: Install latest version of Chocolatey
|
- name: Install latest version of Chocolatey
|
||||||
chocolatey.chocolatey.win_chocolatey:
|
chocolatey.chocolatey.win_chocolatey:
|
||||||
name: chocolatey
|
name: chocolatey
|
||||||
@@ -30,22 +13,6 @@
|
|||||||
|
|
||||||
- name: Installing additional packages using Chocolatey
|
- name: Installing additional packages using Chocolatey
|
||||||
chocolatey.chocolatey.win_chocolatey:
|
chocolatey.chocolatey.win_chocolatey:
|
||||||
name:
|
name: "{{ item }}"
|
||||||
- googlechrome
|
|
||||||
- putty
|
|
||||||
state: latest
|
state: latest
|
||||||
ignore_checksums: true
|
loop: "{{ base_chocolatey_packages }}"
|
||||||
|
|
||||||
- name: Updating the operating system
|
|
||||||
ansible.windows.win_updates:
|
|
||||||
category_names:
|
|
||||||
- SecurityUpdates
|
|
||||||
- CriticalUpdates
|
|
||||||
reject_list:
|
|
||||||
- 5034439
|
|
||||||
- 5034441
|
|
||||||
reboot: true
|
|
||||||
register: win_updates
|
|
||||||
until: not win_updates.failed
|
|
||||||
retries: 5
|
|
||||||
delay: 300
|
|
||||||
|
|||||||
Reference in New Issue
Block a user