database.js
894 Bytes
const path = require("path");
module.exports = ({ env }) => ({
// connection: {
// client: 'sqlite',
// connection: {
// filename: path.join(__dirname, '..', env('DATABASE_FILENAME', '.tmp/data.db')),
// },
// useNullAsDefault: true,
// },
// Postgresql connection settings.
// Reference: https://strapi.io/blog/postgre-sql-and-strapi-setup
connection: {
client: "postgres",
connection: {
host: env("DATABASE_HOST", "localhost"),
port: env.int("DATABASE_PORT", 5432),
database: env("DATABASE_NAME", "strapidev"),
user: env("DATABASE_USERNAME", "harishpatel"),
password: env("DATABASE_PASSWORD", "harishpatel"),
schema: env("DATABASE_SCHEMA", "public"), // Not required
// ssl: {
// rejectUnauthorized: env.bool("DATABASE_SSL_SELF", false)
// }
ssl: false,
},
debug: false,
},
});