cache resources exhausted with magick package on

Hi, I'm having the same issue as this issue where I get a cache resources exhausted error when writing images using the {magick} package in an app hosted on

As noted in the github issue, this stackoverflow answer suggests that I edit policy.xml, but I don't know how to do that on

My specific app creates overlays of several images using {magick}. The issue also does not occur when running the app locally - it's only when running on

I've already increased the instance size to 8GB and it keeps occurring. I have to believe this is just some setting issue, but I don't know where to look.

Does anyone have any suggestions about this?