thank you. So if I have self setup postgres on my own cloud computer would I just leave admin: auth: secret
blank? It says that environmental configs do not need to contain all these values so long as they exist in the default
which I’m having a hard time understanding what it means.
edit: it says the default undefined
which I guess it means I could just leave it blank, right?
module.exports = ({ env }) => ({
host: env('HOST', '0.0.0.0'),
port: env.int('PORT', 1337),
admin: {
auth: {
secret: env('ADMIN_JWT_SECRET', 'someSecretKey'),
},
},
});
this is my current database.js
in case it helps
module.exports = ({ env }) => {
if (env('NODE_ENV') === 'development') {
return {
defaultConnection: 'default',
connections: {
default: {
connector: 'bookshelf',
settings: {
client: 'sqlite',
filename: env('DATABASE_FILENAME', '.tmp/data.db'),
},
options: {
useNullAsDefault: true,
},
},
},
}
} else {
return {
defaultConnection: 'default',
connections: {
default: {
connector: 'bookshelf',
settings: {
client: 'postgres',
host: env('DATABASE_HOST', 'localhost'),
port: env.int('DATABASE_PORT', 5432),
database: env('DATABASE_NAME', 'strapi'),
username: env('DATABASE_USERNAME', 'john'),
password: env('DATABASE_PASSWORD', 'password'),
schema: env('DATABASE_SCHEMA', 'public'), // Not Required
ssl: {
rejectUnauthorized: env.bool('DATABASE_SSL_SELF', false), // For self-signed certificates
},
},
options: {
ssl: env.bool('DATABASE_SSL', false),
},
},
},
}
}
};