Inexperienced developer trying to set up a Strapi CMS on Render hosting. I need to configure a disk so that image uploads in strapi don’t get lost whenever I deploy. I have no idea what to enter for Mount Path. Can anyone explain this?
The mount path will depend on where your Strapi application is configured to save these uploads. We do have a Strapi example here which uses Postgres and file uploads to a disk: GitHub - render-examples/strapi-postgres: Deploy Strapi with PostgreSQL on Render.
If you take a look at the render.yaml here, the mount path for the disk is set to
Thanks Jade, I’ll try that now.
If you don’t mind helping me some more, I’d like to understand how one figures out that path. public/uploads is in my Strapi project directory, so I’m guessing that opt/render/project/src is from the hosting filesystem? Is that correct, and if so, how is one supposed to figure that out? I poked around the Render dashboard quite a bit and didn’t see anything that would show me the folder structure of my hosted environment. I haven’t been doing web development for long, so maybe the answer would be obvious to someone with more experience, but to me this seems rather cryptic.
opt/render/project/src is where the project files are located on native environments. You can navigate the hosted filesystem in the Shell tab of your service. If you navigate to your
/public/uploads folder and use the command
pwd that should return the full file path. I hope that helps to clarify!
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.