@Tal_Shemer, its probably because your database config file is not following the Strapi v4 format. You should have something like this:
const parse = require("pg-connection-string").parse;
const config = parse(process.env.DATABASE_URL);
const { host, port, database, user, password } = parse(process.env.DATABASE_URL);
module.exports = () => ({
connection: {
client: "postgres",
connection: {
host,
port,
database,
user,
password,
ssl: {
rejectUnauthorized: false,
},
},
debug: false,
},
});
But also be aware that DATABASE_URL
env var causes potentially an issue. Please refer to this post: Getting strapi working on digitalocean app plattform - #2 by tw1t611
Let me know if this works out for you (cause for me its not haha)