Directus deployment aborted

Hi there, I could need some assistance on this:
I followed the instructions for directus deployment https://docs.cleavr.io/guides/directus/.
My deployment gets aborted at “Build Assets”. I tried multiple times with different databases but could not get it to work. What could cause this error?
Thanks for help.

It’s difficult to tell without the error - which abort won’t provide an error.

Since it occurred on the build step, it could be the server doesn’t have enough memory to build the app. You can try enabling GitHub Actions for the project to be built on GitHub.

Ok - I see the issue. I tried the instructions and it needs to be updated a bit.

  1. Create a new deployment hook and add it after copy project. The .env file needs to be linked:

cd {{ releasePath }}
ln -s {{ projectPath }}/.env .env

There was actually a bug with linking .env that we fixed so this isn’t needed now

  1. In environment, make sure to add in a PUBLIC_URL variable, the db variables used when creating the db, and some random value for KEY and SECRET.

  2. In Web App Settings > Build, make sure port is 8055 there as well. Note - in Cleavr 2.0 you can set the port number under advanced settings when you create a new site which would make this step and the reverse_proxy step needless

That should be it.

I’ll update the guide to make it more clear.

Hint: if you see an issue like a 502, check the server > services > NodeJS heartbeat - it will output PM2 logs that almost always flags what the issue might be.