@mimik/configuration 4.4.12 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/index.js +8 -2
- package/lib/common.js +2 -2
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -63,7 +63,8 @@ The following environement variables are being used for the configuration:
|
|
|
63
63
|
| SERVER_ID | service id | uuid.v4() | serverSettings.id |
|
|
64
64
|
| CUSTOMER_CODE | customer code associated with the service instance | '' | serverSettings.customerCode | empty string
|
|
65
65
|
| SWAGGER_FILE_DIRECTORY | directory where the api definition is located | ./api | serverSettings.api | [1]
|
|
66
|
-
|
|
|
66
|
+
| BITBUCKET_USERNAME | username to access bitbucket read access on the swagger repos | | serverSettings.apiBasicAuth.username
|
|
67
|
+
| BITBUCKET_PASSWORD | password to access bitbucket read access on the swagger repos | | serverSettings.apiBasicAuth.password
|
|
67
68
|
| SERVER_SECURITY_SET | switch to enable or disable the token interpretation | on | serverSettings.securitySet | only active if environment is `local`
|
|
68
69
|
| INTERCEPT_ERROR | switch to use or not the errorIntercept option | on | serverSettings.interceptError | must be set to off for mID
|
|
69
70
|
| SERVER_PORT | port of the server | | serverSettings.port |
|
package/index.js
CHANGED
|
@@ -442,7 +442,12 @@ if (!isMSTSet) {
|
|
|
442
442
|
configuration.dependencies = {};
|
|
443
443
|
}
|
|
444
444
|
if (process.env.OAUTH_GENERIC_PREVIOUS_KEY) configuration.security.generic.previousKey = process.env.OAUTH_GENERIC_PREVIOUS_KEY;
|
|
445
|
-
if (process.env.
|
|
445
|
+
if (process.env.BITBUCKET_USERNAME) {
|
|
446
|
+
configuration.serverSettings.apiBasicAuth = {
|
|
447
|
+
username: process.env.BITBUCKET_USERNAME,
|
|
448
|
+
password: process.env.BITBUCKET_PASSWORD,
|
|
449
|
+
};
|
|
450
|
+
}
|
|
446
451
|
configuration.logInfo = setupLog();
|
|
447
452
|
configuration.locationProvider = setupLocationProvider();
|
|
448
453
|
|
|
@@ -485,7 +490,8 @@ configuration.locationProvider = setupLocationProvider();
|
|
|
485
490
|
* | SERVER_ID | service id | uuid.v4() | serverSettings.id |
|
|
486
491
|
* | CUSTOMER_CODE | customer code associated with the service instance | '' | serverSettings.customerCode | empty string
|
|
487
492
|
* | SWAGGER_FILE_DIRECTORY | directory where the api definition is located | ./api | serverSettings.api | [1]
|
|
488
|
-
* |
|
|
493
|
+
* | BITBUCKET_USERNAME | username to access bitbucket read access on the swagger repos | | serverSettings.apiBasicAuth.username
|
|
494
|
+
* | BITBUCKET_PASSWORD | password to access bitbucket read access on the swagger repos | | serverSettings.apiBasicAuth.password
|
|
489
495
|
* | SERVER_SECURITY_SET | switch to enable or disable the token interpretation | on | serverSettings.securitySet | only active if environment is `local`
|
|
490
496
|
* | INTERCEPT_ERROR | switch to use or not the errorIntercept option | on | serverSettings.interceptError | must be set to off for mID
|
|
491
497
|
* | SERVER_PORT | port of the server | | serverSettings.port |
|
package/lib/common.js
CHANGED
|
@@ -43,8 +43,8 @@ const DEFAULT_DYNAMO_THROUGHPUT_WRITE = 1;
|
|
|
43
43
|
const DEFAULT_DYNAMO_THROUGHPUT = 1;
|
|
44
44
|
|
|
45
45
|
const DEFAULT_MONGO_MAX_POOL_SIZE = 10;
|
|
46
|
-
const DEFAULT_MONGO_MIN_POOL_SIZE =
|
|
47
|
-
const DEFAULT_MONGO_MAX_IDLE_TIME =
|
|
46
|
+
const DEFAULT_MONGO_MIN_POOL_SIZE = 0;
|
|
47
|
+
const DEFAULT_MONGO_MAX_IDLE_TIME = 30000; // in ms
|
|
48
48
|
const DEFAULT_MONGO_KEEP_ALIVE = true;
|
|
49
49
|
const DEFAULT_MONGO_KEEP_ALIVE_INITIAL_DELAY = 300000; // in ms
|
|
50
50
|
const DEFAULT_MONGO_SOCKET_TIMEOUT = 20000; // in ms
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mimik/configuration",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"description": "Common configuration for mimik services",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@mimik/request-helper": "^1.7.8",
|
|
34
|
-
"@mimik/sumologic-winston-logger": "^1.6.
|
|
35
|
-
"@mimik/user-filters": "1.3.
|
|
34
|
+
"@mimik/sumologic-winston-logger": "^1.6.15",
|
|
35
|
+
"@mimik/user-filters": "1.3.6",
|
|
36
36
|
"ip": "2.0.0",
|
|
37
37
|
"lodash": "4.17.21",
|
|
38
38
|
"uuid": "9.0.0"
|
|
@@ -40,13 +40,13 @@
|
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@mimik/eslint-plugin-dependencies": "^2.4.5",
|
|
42
42
|
"@mimik/eslint-plugin-document-env": "^1.0.5",
|
|
43
|
-
"eslint": "8.
|
|
43
|
+
"eslint": "8.38.0",
|
|
44
44
|
"eslint-config-airbnb": "19.0.4",
|
|
45
|
-
"eslint-plugin-import": "2.
|
|
46
|
-
"eslint-plugin-jsx-a11y": "6.
|
|
47
|
-
"eslint-plugin-react": "7.
|
|
45
|
+
"eslint-plugin-import": "2.27.5",
|
|
46
|
+
"eslint-plugin-jsx-a11y": "6.7.1",
|
|
47
|
+
"eslint-plugin-react": "7.32.2",
|
|
48
48
|
"eslint-plugin-react-hooks": "4.6.0",
|
|
49
|
-
"husky": "8.0.
|
|
49
|
+
"husky": "8.0.3",
|
|
50
50
|
"jsdoc-to-markdown": "8.0.0"
|
|
51
51
|
}
|
|
52
52
|
}
|