Remove settings.apis.v1 defaults (#2365)

GitOrigin-RevId: 53d191a080fd50b83236f4e16a0dd10e72e705ad
This commit is contained in:
Miguel Serrano 2019-11-20 12:23:15 +01:00 committed by sharelatex
parent 0aad6f2bc8
commit e4d180955f
2 changed files with 16 additions and 4 deletions

View file

@ -15,10 +15,16 @@ httpAuthUsers[httpAuthUser] = httpAuthPass
sessionSecret = process.env['SESSION_SECRET'] or "secret-please-change"
if process.env['V1_API_URL'] or process.env['V1_HOST']
v1Api =
url: process.env['V1_API_URL'] or "http://#{process.env['V1_HOST'] or 'localhost'}:5000"
user: process.env['V1_API_USER'] or 'overleaf'
pass: process.env['V1_API_PASSWORD'] or 'password'
url: process.env['V1_API_URL'] or "http://#{process.env['V1_HOST']}:5000"
user: process.env['V1_API_USER']
pass: process.env['V1_API_PASSWORD']
else
v1Api =
url: undefined
user: undefined
pass: undefined
module.exports = settings =

View file

@ -1,10 +1,16 @@
v1Api =
url: "http://#{process.env['V1_HOST'] or 'localhost'}:5000"
user: process.env['V1_API_USER'] or 'overleaf'
pass: process.env['V1_API_PASSWORD'] or 'password'
module.exports =
enableSubscriptions: true
apis:
v1:
url: v1Api.url
user: v1Api.user
pass: v1Api.pass
recurly:
# Set up our own mock recurly server
url: 'http://localhost:6034'