I'm working on a hobby project using strapi as backend and nextjs as front end. I wanted to deploy strapi somewhere. I have tried with heroku and render and both are fantastic but not free. So I was doing some research on supabase for database and netlify for webservice. When I tried connecting the database(that created on supabase), I kept encountering SSL error. It could be unrelated but before digging further I wanted to confirm if its possible to do so. Can someone share some insight?
If its possible, can someone share the configurations and how to do it? Thanks in advance.
This was the error that I was getting.
Sep 14 10:41:05 PM $ strapi start
Sep 14 10:41:36 PM [2023-09-14 17:11:36.869] debug: ⛔️ Server wasn't able to start properly.
Sep 14 10:41:36 PM [2023-09-14 17:11:36.872] error: self signed certificate in certificate chain
Sep 14 10:41:36 PM Error: self signed certificate in certificate chain
Sep 14 10:41:36 PM at TLSSocket.onConnectSecure (node:_tls_wrap:1539:34)
Sep 14 10:41:36 PM at TLSSocket.emit (node:events:513:28)
Sep 14 10:41:36 PM at TLSSocket.emit (node:domain:489:12)
Sep 14 10:41:36 PM at TLSSocket._finishInit (node:_tls_wrap:953:8)
Sep 14 10:41:36 PM at TLSWrap.ssl.onhandshakedone (node:_tls_wrap:734:12)
Sep 14 10:41:37 PM error Command failed with exit code 1.
I finally found out that the actual issue was with DATABASE_SSL=false
Earlier I was using DATABASE_SSL=true
. I was able to successfully deploy strap webservice on render using the database created in supabase. All you have to do is update the env variables from supabase to render. Please make sure pg
is installed on strapi. It works like charm!