I just updated my kb_list var with using single and even double quotes but its simply ignoring variable file and just rebooting windows server.
*kb_list: ['KB5006065', 'KB890830']* *kb_list: ["KB5006065", "KB890830"]* These are the changes you were suggesting or anything different? On Wednesday, November 10, 2021 at 10:58:47 PM UTC+5:30 [email protected] wrote: > That kb_list var has unquoted items? > > On Wed, 10 Nov 2021 at 16:38, Jitendra Ingale <[email protected]> wrote: > >> Folks, >> >> I am using below pasted playbook for windows server patching which has >> variable file defined along with. >> It is supposed to take KB number mentioned in variable file and install >> it on server, followed by server reboot. >> >> Problem is that, the said playbook is getting executed without any issue >> and also rebooting the server *however its not installing mentioned KB >> patches on server* as expected. >> >> Please suggest. >> >> *Playbook* >> *---* >> *- hosts: win* >> * vars_files:* >> * - patch_list1.yml* >> * tasks:* >> * - name: Install only particular updates based on the KB >> numbers* >> * win_updates:* >> * category_names:* >> * - SecurityUpdates* >> * - CriticalUpdates* >> * - UpdateRollups* >> * - DefinitionUpdates* >> * - Updates* >> * - Application* >> * - Connectors* >> * - DeveloperKits* >> * - FeaturePacks* >> * - Guidance* >> * - ServicePacks* >> * - Tools* >> * - UpdateRollups* >> >> * whitelist: "{{ kb_list|default(omit,true )}}"* >> * log_path: C:\WinUpdates.txt* >> * # - debug: msg " It's rebooting "* >> * - name: Rebooting the machine* >> * win_reboot:* >> >> >> *Variable File (patch_list1.yml)* >> *kb_list: [KB5006065, KB890830]* >> >> -- >> 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/ab22a276-05e4-48af-96eb-f48d15fe5ea4n%40googlegroups.com >> >> <https://groups.google.com/d/msgid/ansible-project/ab22a276-05e4-48af-96eb-f48d15fe5ea4n%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> > -- > Sent from a mobile device - please excuse the brevity, spelling and > punctuation. > -- 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/4aa1b89f-ae48-4ac4-9376-0e140c5a3ed0n%40googlegroups.com.
