{"status":"500","message":"Couldn't find database connection \"db\".","stack":"Error: Couldn't find database connection \"db\".\n at App.getDbConnection (/opt/node_app/lib/core/app.js:226:15)\n at new DatabaseProvider (/opt/node_app/lib/auth/database.js:9:23)\n at App.setAuthProvider (/opt/node_app/lib/core/app.js:132:26)\n at App.getAuthProvider (/opt/node_app/lib/core/app.js:149:31)\n at App.restrict (/opt/node_app/lib/modules/auth.js:42:37)\n at App._exec (/opt/node_app/lib/core/app.js:393:57)\n at App.exec (/opt/node_app/lib/core/app.js:335:20)\n at App.exec (/opt/node_app/lib/core/app.js:328:28)\n at /opt/node_app/lib/core/middleware.js:52:44\n at Layer.handle [as handle_request] (/opt/node_app/node_modules/express/lib/router/layer.js:95:5)"}
Yep, still there. I’m able to access the DB locally when rending the site. On staging I’m also able to access the DB fine from within the DB Manager - but when I deploy and try to access the site on the server I get this error.
@patrick - I tried changing the connections to Connections in the schema, and also the actual folder name to Connections, I redeployed and now get this error:
{"status":"500","message":"knex: Required configuration option 'client' is missing.","stack":"Error: knex: Required configuration option 'client' is missing.\n at new Client (/opt/node_app/node_modules/knex/lib/client.js:54:11)\n at Knex (/opt/node_app/node_modules/knex/lib/knex.js:53:28)\n at App.setDbConnection (/opt/node_app/lib/core/app.js:206:25)\n at App.getDbConnection (/opt/node_app/lib/core/app.js:223:25)\n at new DatabaseProvider (/opt/node_app/lib/auth/database.js:9:23)\n at App.setAuthProvider (/opt/node_app/lib/core/app.js:132:26)\n at App.getAuthProvider (/opt/node_app/lib/core/app.js:149:31)\n at App.restrict (/opt/node_app/lib/modules/auth.js:42:37)\n at App._exec (/opt/node_app/lib/core/app.js:393:57)\n at App.exec (/opt/node_app/lib/core/app.js:335:20)"}
Noting I also tried just changing the folder name, and leaving the schema. Same issue and error.
{“status”:“500”,“message”:“knex: Required configuration option ‘client’ is missing.”,“stack”:“Error: knex: Required configuration option ‘client’ is missing.\n at new Client (/opt/node_app/node_modules/knex/lib/client.js:54:11)\n at Knex (/opt/node_app/node_modules/knex/lib/knex.js:53:28)\n at App.setDbConnection (/opt/node_app/lib/core/app.js:206:25)\n at App.getDbConnection (/opt/node_app/lib/core/app.js:223:25)\n at new DatabaseProvider (/opt/node_app/lib/auth/database.js:9:23)\n at App.setAuthProvider (/opt/node_app/lib/core/app.js:132:26)\n at App.getAuthProvider (/opt/node_app/lib/core/app.js:149:31)\n at App.restrict (/opt/node_app/lib/modules/auth.js:42:37)\n at App._exec (/opt/node_app/lib/core/app.js:393:57)\n at App.exec (/opt/node_app/lib/core/app.js:335:20)”}
{“status”:“500”,“message”:“knex: Required configuration option ‘client’ is missing.”,“stack”:“Error: knex: Required configuration option ‘client’ is missing.\n at new Client (/opt/node_app/node_modules/knex/lib/client.js:54:11)\n at Knex (/opt/node_app/node_modules/knex/lib/knex.js:53:28)\n at App.setDbConnection (/opt/node_app/lib/core/app.js:206:25)\n at App.getDbConnection (/opt/node_app/lib/core/app.js:223:25)\n at new DatabaseProvider (/opt/node_app/lib/auth/database.js:9:23)\n at App.setAuthProvider (/opt/node_app/lib/core/app.js:132:26)\n at App.getAuthProvider (/opt/node_app/lib/core/app.js:149:31)\n at App.restrict (/opt/node_app/lib/modules/auth.js:42:37)\n at App._exec (/opt/node_app/lib/core/app.js:393:57)\n at App.exec (/opt/node_app/lib/core/app.js:335:20)”}