mirror of
https://github.com/xuthus83/pigallery2.git
synced 2024-11-03 21:04:03 +08:00
adding mysql setting alliances
This commit is contained in:
parent
67ba7a707f
commit
1f8bc784ef
@ -3,6 +3,8 @@ language: node_js
|
||||
node_js:
|
||||
- '10'
|
||||
- '11'
|
||||
env:
|
||||
- MYSQL_HOST='localhost' MYSQL_PASSWORD='' MYSQL_USERNAME='root' MYSQL_DATABASE='pigallery2_test'
|
||||
services:
|
||||
- mysql
|
||||
addons:
|
||||
|
@ -63,7 +63,11 @@ export class PrivateConfigClass extends PublicConfigClass implements IPrivateCon
|
||||
public load() {
|
||||
ConfigLoader.loadBackendConfig(this,
|
||||
path.join(__dirname, './../../../config.json'),
|
||||
[['PORT', 'Server-port']]);
|
||||
[['PORT', 'Server-port'],
|
||||
['MYSQL_HOST', 'Server-database-mysql-host'],
|
||||
['MYSQL_PASSWORD', 'Server-database-mysql-password'],
|
||||
['MYSQL_USERNAME', 'Server-database-mysql-username'],
|
||||
['MYSQL_DATABASE', 'Server-database-mysql-database']]);
|
||||
|
||||
if (Utils.enumToArray(UserRoles).map(r => r.key).indexOf(this.Client.unAuthenticatedUserRole) === -1) {
|
||||
throw new Error('Unknown user role for Client.unAuthenticatedUserRole, found: ' + this.Client.unAuthenticatedUserRole);
|
||||
|
Loading…
Reference in New Issue
Block a user