Is it just me or is anyone else having issues using Chef to run windows update on remote nodes? I tend to use the PowerShell block to send a PowerShell command to run the windows update. When chef runs it immediately returns that the command has ran successfully yet when you log into the remote node and status the updates nothing changes (nothing happens). I am not trying to make this super hard by developing some elaborate scripts. I think something like this should be rather simple, but for some reason it isn't. Please share what your doing that is successful?
And the PSWindowsUpdate module is not included with Powershell by default, which is where the Install-WindowsUpdate module comes from. I assume you're pre-installing that before you call your script?
Yes I user chef and several cookbooks is used for the pre-install and was hoping that it would work, but I have run into issues where it just doesn't work.
What I would recommend is dropping a script and setting up a scheduled task via Chef. IMO don't treat Chef like a scheduling service, it's config management. Updates can take time to install, sometimes requires reboots, etc.
You can checkout how we did this at FB. https://youtu.be/azP3I5tm3ho