gatsby-source-notion-api icon indicating copy to clipboard operation
gatsby-source-notion-api copied to clipboard

image expired in one hour

Open jerry2714 opened this issue 2 years ago • 2 comments

Hi, I have noticed that image from notion is provided as s S3 resource with 1 hour expiration time, so I have to rebuild the site every hour to keep the image shows up.Is it possible to keep the image in the build to solve the expiration issue? Thank you!

jerry2714 avatar May 07 '22 17:05 jerry2714

Ditto on this. I currently just run an automation to rebuild my site on vercel every hour, and make sure on each build the client will also refresh (otherwise there will be dead links). Excited to see if there are better work arounds.

conradlin avatar May 09 '22 09:05 conradlin

I didn't notice that there is a solution in README.md. The createRemoteFileNode from gatsby-source-filesystem can keep the image in local and generate a file node with a publicURL field. We can just replace the remote URL of images in the content with the publicURL to solve this problem. @conradlin I think it might be a good solution.

jerry2714 avatar May 12 '22 16:05 jerry2714