@yobytechautomation/config-lib 0.3.1 → 0.3.3

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.
@@ -111,12 +111,17 @@ class BaseConfigServiceImpl {
111
111
  .createHmac("sha256", secret)
112
112
  .update(apiKey + machineId)
113
113
  .digest("hex");
114
+ console.log('DEBUG SIGNATURE:', signature);
115
+ const clientIp = await axios_1.default.get('https://api.ipify.org?format=json')
116
+ .then(res => res.data.ip)
117
+ .catch(() => 'unknown');
114
118
  const res = await axios_1.default.get(url, {
115
119
  headers: {
116
120
  "x-api-key": apiKey,
117
121
  "x-license-secret": secret,
118
122
  "x-machine-id": machineId,
119
123
  'x-signature': signature,
124
+ 'x-client-ip': clientIp,
120
125
  },
121
126
  timeout: 5000,
122
127
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yobytechautomation/config-lib",
3
- "version": "0.3.1",
3
+ "version": "0.3.3",
4
4
  "description": "Shared multi-environment configuration helpers for SDC NestJS services",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",