I have a server where I use Nginx and I have a directory where I only store images and it is accessible from a subdomain. This is all working fine.
Now, I want that if I share that image link on, for example WhatsApp, a preview is shown. From what I know, this can be achieved by adding meta information to the returned HTML. So if instead of serving images I was serving HTML documents, I would add the tags with the information for the preview.
Is there a way to achieve this on Nginx? Somehow injecting some information before serving the image?
Thanks.