Looping over a list to use with with_fileglob

I want to loop over a hash list that will provide two items.

  1. The file glob
  2. the destination

Is this possible via some sort of nested loop and with_fileglob?

The list would look something like below, and I’m hoping a single ‘copy’ command using with_fileglob can accomplish it. The list in actuality will be several dozen lines long and passed as a parameter so hardcoding it is not that easy.

list_of_items:

  • {{ glob: “/path/to/items/*”, dest: “/new/path/to/items/” }}
  • {{ glob: “/path/to/moreitems/*”, dest: “/new/path/to/moreitems/” }}
    etc