ref: Rename environment variable

pull/409/head
Maksim Eltyshev 3 years ago
parent 9f33778064
commit 60d9ceb4b5

@ -23,13 +23,14 @@ services:
- TRUST_PROXY=0 - TRUST_PROXY=0
- DATABASE_URL=postgresql://postgres@postgres/planka - DATABASE_URL=postgresql://postgres@postgres/planka
- SECRET_KEY=notsecretkey - SECRET_KEY=notsecretkey
# related: https://github.com/knex/knex/issues/2354 # related: https://github.com/knex/knex/issues/2354
# As knex does not pass query parameters from the connection string we # As knex does not pass query parameters from the connection string we
# have to use environment variables in order to pass the desired values, e.g. # have to use environment variables in order to pass the desired values, e.g.
# PGSSLMODE=<value> # - PGSSLMODE=<value>
# Configure knex to accept SSL certificates # Configure knex to accept SSL certificates
# REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false # - KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false
depends_on: depends_on:
- postgres - postgres

@ -15,7 +15,7 @@ SECRET_KEY=notsecretkey
# PGSSLMODE=<value> # PGSSLMODE=<value>
# Configure knex to accept SSL certificates # Configure knex to accept SSL certificates
# REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false # KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false
## Do not edit this ## Do not edit this

@ -7,7 +7,7 @@ dotenv.config({
}); });
function buildSSLConfig() { function buildSSLConfig() {
if (process.env.REJECT_UNAUTHORIZED_SSL_CERTIFICATE === 'false') { if (process.env.KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE === 'false') {
return { return {
rejectUnauthorized: false, rejectUnauthorized: false,
}; };

Loading…
Cancel
Save