Can someone here explain to me exactly how I can get STRAPI to run on my coolify instance? So far I haven’t been able to do it myself. Neither with docker or via deploy
This topic has been created from a Discord post (1246446488150872104) to give it more visibility.
It will be on Read-Only mode here.
Join the conversation on Discord
go check on coolify discord channel, there are a thread talked about it and someone had figured it out
I added a nixpacks.toml
file in the root of the Strapi v5 project. ```[phases.install]
cmds = [‘yarn install’]
[phases.build]
cmds = [‘yarn build’]
[variables]
NODE_ENV = ‘production’
NIXPACKS_NODE_VERSION = ‘20’
[start]
cmd = ‘yarn start’```
I managed to host it on Coolify but i get this error when trying to transfer data to it:
error: [FATAL] restore failed Error: The backup folder for the assets could not be created inside the public folder. Please ensure Strapi has write permissions on the public directory Transfer process failed.
That’s a docker issue, you mount uploads
instead of public
Yes thanks I figured it out but seems like you first have to create the uploads folder in public.
I can deploy strapi on my coolify alone but can not deploy nextjs frontend with it. any one figured it out?
Can you share the config/steps for mounting the public folder please?
For those wondering how to configure persistent storage for the public folder(where strapi upload stuff), follow these steps before deploying your app on Coolify.
- Click on the Configuration tab
- Clock on the Storages menu option
- Click Add to add a new location to store stuff
- Under the Volume Mount heading, enter the values for the name & destination path
- Ensure that the destination path starts with
/app
. So for persisting the public folder items, the destination path should be set to /app/public
- Click the Save button that is below the Volume Mount section.
- Redeploy your app.
- Go to the url and log into your Strapi app then upload something.
- Redeploy your app
- Log back into strapi to see if the file is still there and can be viewed in a new window
Thanks for this guide! But I don´t get why I should start the destination path with /app. In addition, I have a configuration with ssd + hdd and I was wondering how I should link just the heavy files in my hdd. I think I need a way to link just /public to an internal folder such as /mnt/hdd/uploads and for the other directories just let coolify doing its job setting a persistent volume. Do you have any suggestion?