itlab-internal-services 1.2.1 → 1.2.2
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/dist/internal.module.js +3 -3
- package/package.json +2 -2
package/dist/internal.module.js
CHANGED
|
@@ -26,7 +26,7 @@ const axios_1 = __importDefault(require("axios"));
|
|
|
26
26
|
const guards_1 = require("./guards");
|
|
27
27
|
const internal_constants_1 = require("./internal.constants");
|
|
28
28
|
const services_1 = require("./services");
|
|
29
|
-
const
|
|
29
|
+
const getAxiosInstance = (config) => axios_1.default.create({
|
|
30
30
|
baseURL: 'https://services.svi-itlab.com/',
|
|
31
31
|
headers: { 'X-itlab-k8s-auth': config.token },
|
|
32
32
|
});
|
|
@@ -35,7 +35,7 @@ let InternalModule = InternalModule_1 = class InternalModule {
|
|
|
35
35
|
return {
|
|
36
36
|
module: InternalModule_1,
|
|
37
37
|
providers: [
|
|
38
|
-
{ provide: internal_constants_1.AXIOS_INSTANCE_TOKEN, useValue:
|
|
38
|
+
{ provide: internal_constants_1.AXIOS_INSTANCE_TOKEN, useValue: getAxiosInstance(options) },
|
|
39
39
|
{ provide: internal_constants_1.INTERNAL_MODULE_ID, useValue: (0, random_string_generator_util_1.randomStringGenerator)() },
|
|
40
40
|
{ provide: internal_constants_1.INTERNAL_MODULE_TARGET, useValue: options.target },
|
|
41
41
|
{ provide: internal_constants_1.INTERNAL_MODULE_HEADER_TOKEN, useValue: options.token },
|
|
@@ -51,7 +51,7 @@ let InternalModule = InternalModule_1 = class InternalModule {
|
|
|
51
51
|
...this.createAsyncProviders(options),
|
|
52
52
|
{
|
|
53
53
|
provide: internal_constants_1.AXIOS_INSTANCE_TOKEN,
|
|
54
|
-
useFactory: (config) =>
|
|
54
|
+
useFactory: (config) => getAxiosInstance(config),
|
|
55
55
|
inject: [internal_constants_1.INTERNAL_MODULE_OPTIONS],
|
|
56
56
|
},
|
|
57
57
|
{
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"email": "timo.scheuermann@sv-informatik.de",
|
|
6
6
|
"url": "https://timos.design"
|
|
7
7
|
},
|
|
8
|
-
"version": "1.2.
|
|
8
|
+
"version": "1.2.2",
|
|
9
9
|
"type": "commonjs",
|
|
10
10
|
"files": [
|
|
11
11
|
"dist"
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"prepack": "npm run build"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"axios": "1.
|
|
25
|
+
"axios": "^1.2.3",
|
|
26
26
|
"itlab-functions": "^0.2.0"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|