Can anyone help with this? On Monday, July 6, 2020 at 10:59:39 AM UTC-7, Alan Woods wrote: > > Hello I am trying to install windows 10 feature updates or upgrades. The > playbook I am using seems to download it but it will not install it. I > still need to go into windows updates and hit retry then it installs. This > is the playbook I am currently using: > > > --- > - hosts: win10-pro-1 > gather_facts: yes > tasks: > - name: Re-Boot PC before upgrade > win_reboot: > > - name: Upgrade Windows 10 > win_updates: > category_names: > - Upgrades > state: installed > register: update_result > > - name: reboot host if required > win_reboot: > when: update_result.reboot_required > > I just added the first task to re-boot the PC first because I get errors > sometimes that the PC needs to be re-booted first. The playbook runs with > no errors and this is the what I get when running it. > > [vagrant@controller win_10_Updates]$ ansible-playbook testFeatureUPdate.yml > > > PLAY [win10-pro-1] > *********************************************************************************************************************** > > TASK [Gathering Facts] > ******************************************************************************************************************* > ok: [win10-pro-1] > > TASK [Re-Boot PC before upgrade] > ********************************************************************************************************* > changed: [win10-pro-1] > > TASK [Upgrade Windows 10] > **************************************************************************************************************** > changed: [win10-pro-1] > > TASK [reboot host if required] > *********************************************************************************************************** > changed: [win10-pro-1] > > PLAY RECAP > ******************************************************************************************************************************* > win10-pro-1 : ok=4 changed=3 unreachable=0 failed= > 0 skipped=0 rescued=0 ignored=0 > > [vagrant@controller win_10_Updates]$ > > > > I am trying to get Ansible to install the upgrade and re-boot the PC if it > needs to be without having to touch the windows 10 PC at all. Does anyone > know if this is achievable? >
-- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/b64936a8-6ab0-422b-a4b7-b584c38a096co%40googlegroups.com.
