Describe the issue/error/question
My mother has kindly offered to help me with my business affairs and is filing my mountains of paperwork for me as I scan it. I’ve successfully created a workflow that uploads new scans to Nextcloud and then sends an email to her with some details about the file and a link to the folder in which it’s saved.
This is random both in concept and practice:
I want to embed a random image of her grandchildren taken from a local folder (or Nextcloud, maybe as a step 2), at the bottom of each email to make it a more pleasant experience for her. The best thing I can come up with at the moment is using a static URL to embed the image into the email and creating either a separate workflow or maybe even use a bash script or something to change a list of files from a directory to said filename/URL once per day, however, the trigger for randomisation is not time-based so this wouldn’t really work properly unless it was set to rename ever 1 minute or something like that. That seems too resource intensive and in my opinion it should be possible to use logic to randomly select a file from a list of files rather than manipulate the files to become consistent with the output requirement.
It’s partly a thought experiment for me after having caught the n8n bug in a big way over the last few weeks, and I’m curious to know how others might approach it?