@itentialopensource/adapter-netbox_v33 2.1.10 → 2.1.12
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/CHANGELOG.md +16 -0
- package/SYSTEMINFO.md +2 -2
- package/TAB2.md +1 -1
- package/metadata.json +12 -8
- package/package.json +4 -4
- package/refs?service=git-upload-pack +0 -0
- package/report/adapterInfo.json +4 -4
- package/sampleProperties.json +4 -4
- package/test/integration/adapterTestConnectivity.js +0 -24
- package/test/integration/adapterTestIntegration.js +11 -7
- package/test/unit/adapterTestUnit.js +12 -8
- package/compliance-report.json +0 -9
- package/compliance-report.txt +0 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,20 @@
|
|
|
1
1
|
|
|
2
|
+
## 2.1.12 [10-15-2024]
|
|
3
|
+
|
|
4
|
+
* Changes made at 2024.10.14_19:49PM
|
|
5
|
+
|
|
6
|
+
See merge request itentialopensource/adapters/adapter-netbox_v33!18
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## 2.1.11 [09-12-2024]
|
|
11
|
+
|
|
12
|
+
* add workshop and fix vulnerabilities
|
|
13
|
+
|
|
14
|
+
See merge request itentialopensource/adapters/adapter-netbox_v33!16
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
2
18
|
## 2.1.10 [08-14-2024]
|
|
3
19
|
|
|
4
20
|
* Changes made at 2024.08.14_17:57PM
|
package/SYSTEMINFO.md
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
# NetBox
|
|
2
2
|
|
|
3
3
|
Vendor: NetBox
|
|
4
|
-
Homepage: https://
|
|
4
|
+
Homepage: https://netboxlabs.com/
|
|
5
5
|
|
|
6
6
|
Product: NetBox
|
|
7
|
-
Product Page: https://
|
|
7
|
+
Product Page: https://netboxlabs.com/oss/netbox/
|
|
8
8
|
|
|
9
9
|
## Introduction
|
|
10
10
|
We classify NetBox into the Inventory domain because it contains an inventory of devices, assets, network discovery and topology information.
|
package/TAB2.md
CHANGED
package/metadata.json
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "adapter-netbox_v33",
|
|
3
3
|
"webName": "Adapter for Integration to NetBox Labs NetBox v3.3",
|
|
4
|
+
"supportLevel": "certified",
|
|
4
5
|
"vendor": "NetBox Labs",
|
|
5
6
|
"product": "NetBox",
|
|
7
|
+
"techAlliance": true,
|
|
6
8
|
"osVersion": [],
|
|
7
9
|
"apiVersions": [
|
|
8
10
|
"v.3.3",
|
|
@@ -47,7 +49,7 @@
|
|
|
47
49
|
"storeLink": "",
|
|
48
50
|
"npmLink": "https://www.npmjs.com/package/@itentialopensource/adapter-netbox_v33",
|
|
49
51
|
"repoLink": "https://gitlab.com/itentialopensource/adapters/adapter-netbox_v33",
|
|
50
|
-
"docLink": "https://
|
|
52
|
+
"docLink": "https://gitlab.com/itentialopensource/adapters/adapter-netbox_v33/-/blob/master/README.md?ref_type=heads",
|
|
51
53
|
"demoLinks": [
|
|
52
54
|
{
|
|
53
55
|
"title": "Itential & NetBox: Evolving from a Source of Truth to Automation & Orchestration (ONUG)",
|
|
@@ -71,9 +73,9 @@
|
|
|
71
73
|
"faqLink": "https://docs.itential.com/opensource/docs/troubleshooting-an-adapter",
|
|
72
74
|
"contributeLink": "https://gitlab.com/itentialopensource/adapters/contributing-guide",
|
|
73
75
|
"issueLink": "https://itential.atlassian.net/servicedesk/customer/portals",
|
|
74
|
-
"webLink": "",
|
|
75
|
-
"vendorLink": "https://
|
|
76
|
-
"productLink": "https://
|
|
76
|
+
"webLink": "https://www.itential.com/adapters/netbox-v33/",
|
|
77
|
+
"vendorLink": "https://netboxlabs.com/",
|
|
78
|
+
"productLink": "https://netboxlabs.com/oss/netbox/",
|
|
77
79
|
"apiLinks": [
|
|
78
80
|
{
|
|
79
81
|
"title": "NetBox REST API",
|
|
@@ -86,7 +88,11 @@
|
|
|
86
88
|
"public": true
|
|
87
89
|
}
|
|
88
90
|
],
|
|
89
|
-
"workshopLinks": [
|
|
91
|
+
"workshopLinks": [
|
|
92
|
+
{
|
|
93
|
+
"title": "Bulk IP Address Allocation"
|
|
94
|
+
}
|
|
95
|
+
],
|
|
90
96
|
"workshopHomePage": "https://www.itential.com/get-started/"
|
|
91
97
|
},
|
|
92
98
|
"assets": [],
|
|
@@ -110,7 +116,5 @@
|
|
|
110
116
|
],
|
|
111
117
|
"transformationProjects": [],
|
|
112
118
|
"exampleProjects": []
|
|
113
|
-
}
|
|
114
|
-
"supportLevel": "community",
|
|
115
|
-
"techAlliance": false
|
|
119
|
+
}
|
|
116
120
|
}
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itentialopensource/adapter-netbox_v33",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.12",
|
|
4
4
|
"description": "This adapter integrates with system described as: Netbox v3.3",
|
|
5
5
|
"main": "adapter.js",
|
|
6
6
|
"wizardVersion": "2.44.7",
|
|
7
|
-
"engineVersion": "1.
|
|
7
|
+
"engineVersion": "1.68.2",
|
|
8
8
|
"adapterType": "http",
|
|
9
9
|
"scripts": {
|
|
10
10
|
"artifactize": "npm i && node utils/packModificationScript.js",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"author": "Itential",
|
|
53
53
|
"homepage": "https://gitlab.com/itentialopensource/adapters/adapter-netbox_v33#readme",
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@itentialopensource/adapter-utils": "^5.
|
|
55
|
+
"@itentialopensource/adapter-utils": "^5.9.4",
|
|
56
56
|
"acorn": "^8.12.1",
|
|
57
57
|
"ajv": "^8.17.1",
|
|
58
58
|
"axios": "^1.7.4",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"prompts": "^2.4.2",
|
|
68
68
|
"readline-sync": "^1.4.10",
|
|
69
69
|
"semver": "^7.6.3",
|
|
70
|
-
"winston": "^3.
|
|
70
|
+
"winston": "^3.14.2"
|
|
71
71
|
},
|
|
72
72
|
"devDependencies": {
|
|
73
73
|
"chai": "^4.3.7",
|
|
Binary file
|
package/report/adapterInfo.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "2.1.
|
|
2
|
+
"version": "2.1.10",
|
|
3
3
|
"configLines": 185576,
|
|
4
4
|
"scriptLines": 1783,
|
|
5
5
|
"codeLines": 79704,
|
|
6
|
-
"testLines":
|
|
7
|
-
"testCases":
|
|
8
|
-
"totalCodeLines":
|
|
6
|
+
"testLines": 52904,
|
|
7
|
+
"testCases": 2757,
|
|
8
|
+
"totalCodeLines": 134391,
|
|
9
9
|
"wfTasks": 896
|
|
10
10
|
}
|
package/sampleProperties.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "Adapter-netbox_v33",
|
|
3
3
|
"type": "NetboxV33",
|
|
4
4
|
"properties": {
|
|
5
|
-
"host": "
|
|
5
|
+
"host": "localhost",
|
|
6
6
|
"port": 443,
|
|
7
7
|
"choosepath": "",
|
|
8
8
|
"base_path": "/api",
|
|
@@ -135,7 +135,7 @@
|
|
|
135
135
|
"ostypePrefix": "meraki-",
|
|
136
136
|
"port": "{port}",
|
|
137
137
|
"ipaddress": "{ip_addr}",
|
|
138
|
-
"serial"
|
|
138
|
+
"serial": "{serial}"
|
|
139
139
|
}
|
|
140
140
|
}
|
|
141
141
|
],
|
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
"ostypePrefix": "meraki-",
|
|
162
162
|
"port": "{port}",
|
|
163
163
|
"ipaddress": "{ip_addr}",
|
|
164
|
-
"serial"
|
|
164
|
+
"serial": "{serial}",
|
|
165
165
|
"id": "{myid}"
|
|
166
166
|
}
|
|
167
167
|
}
|
|
@@ -245,7 +245,7 @@
|
|
|
245
245
|
"ostypePrefix": "meraki-",
|
|
246
246
|
"port": "{port}",
|
|
247
247
|
"ipaddress": "{ip_addr}",
|
|
248
|
-
"serial"
|
|
248
|
+
"serial": "{serial}",
|
|
249
249
|
"id": "{myid}"
|
|
250
250
|
}
|
|
251
251
|
}
|
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
/* eslint no-unused-vars: warn */
|
|
5
5
|
|
|
6
6
|
const assert = require('assert');
|
|
7
|
-
const http = require('http');
|
|
8
7
|
const https = require('https');
|
|
9
8
|
const mocha = require('mocha');
|
|
10
9
|
const ping = require('ping');
|
|
@@ -53,29 +52,6 @@ describe('[integration] Adapter Test', () => {
|
|
|
53
52
|
});
|
|
54
53
|
});
|
|
55
54
|
|
|
56
|
-
it('Support HTTP on port 80', (done) => {
|
|
57
|
-
const requestOptions = {
|
|
58
|
-
host,
|
|
59
|
-
port: 80,
|
|
60
|
-
method: 'HEAD'
|
|
61
|
-
};
|
|
62
|
-
|
|
63
|
-
const req = http.request(requestOptions, (res) => {
|
|
64
|
-
try {
|
|
65
|
-
assert.ok(res.statusCode >= 200 && res.statusCode < 400);
|
|
66
|
-
done();
|
|
67
|
-
} catch (error) {
|
|
68
|
-
done(error);
|
|
69
|
-
}
|
|
70
|
-
});
|
|
71
|
-
|
|
72
|
-
req.on('error', (err) => {
|
|
73
|
-
done(err);
|
|
74
|
-
});
|
|
75
|
-
|
|
76
|
-
req.end();
|
|
77
|
-
});
|
|
78
|
-
|
|
79
55
|
it('Support HTTPS on port 443', (done) => {
|
|
80
56
|
const requestOptions = {
|
|
81
57
|
host,
|
|
@@ -36,13 +36,17 @@ const samProps = require(`${adaptdir}/sampleProperties.json`).properties;
|
|
|
36
36
|
// these variables can be changed to run in integrated mode so easier to set them here
|
|
37
37
|
// always check these in with bogus data!!!
|
|
38
38
|
samProps.stub = true;
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
samProps.
|
|
42
|
-
samProps.
|
|
43
|
-
samProps.
|
|
44
|
-
samProps.
|
|
45
|
-
samProps.
|
|
39
|
+
|
|
40
|
+
// uncomment if connecting
|
|
41
|
+
// samProps.host = 'replace.hostorip.here';
|
|
42
|
+
// samProps.authentication.username = 'username';
|
|
43
|
+
// samProps.authentication.password = 'password';
|
|
44
|
+
// samProps.authentication.token = 'password';
|
|
45
|
+
// samProps.protocol = 'http';
|
|
46
|
+
// samProps.port = 80;
|
|
47
|
+
// samProps.ssl.enabled = false;
|
|
48
|
+
// samProps.ssl.accept_invalid_cert = false;
|
|
49
|
+
|
|
46
50
|
if (samProps.request.attempt_timeout < 30000) {
|
|
47
51
|
samProps.request.attempt_timeout = 30000;
|
|
48
52
|
}
|
|
@@ -36,13 +36,17 @@ const samProps = require(`${adaptdir}/sampleProperties.json`).properties;
|
|
|
36
36
|
// these variables can be changed to run in integrated mode so easier to set them here
|
|
37
37
|
// always check these in with bogus data!!!
|
|
38
38
|
samProps.stub = true;
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
samProps.
|
|
42
|
-
samProps.
|
|
43
|
-
samProps.
|
|
44
|
-
samProps.
|
|
45
|
-
samProps.
|
|
39
|
+
|
|
40
|
+
// uncomment if connecting
|
|
41
|
+
// samProps.host = 'replace.hostorip.here';
|
|
42
|
+
// samProps.authentication.username = 'username';
|
|
43
|
+
// samProps.authentication.password = 'password';
|
|
44
|
+
// samProps.authentication.token = 'password';
|
|
45
|
+
// samProps.protocol = 'http';
|
|
46
|
+
// samProps.port = 80;
|
|
47
|
+
// samProps.ssl.enabled = false;
|
|
48
|
+
// samProps.ssl.accept_invalid_cert = false;
|
|
49
|
+
|
|
46
50
|
samProps.request.attempt_timeout = 1200000;
|
|
47
51
|
const attemptTimeout = samProps.request.attempt_timeout;
|
|
48
52
|
const { stub } = samProps;
|
|
@@ -323,7 +327,7 @@ describe('[unit] Netbox_v33 Adapter Test', () => {
|
|
|
323
327
|
assert.equal('^0.4.4', packageDotJson.dependencies.ping);
|
|
324
328
|
assert.equal('^1.4.10', packageDotJson.dependencies['readline-sync']);
|
|
325
329
|
assert.equal('^7.6.3', packageDotJson.dependencies.semver);
|
|
326
|
-
assert.equal('^3.
|
|
330
|
+
assert.equal('^3.14.2', packageDotJson.dependencies.winston);
|
|
327
331
|
done();
|
|
328
332
|
} catch (error) {
|
|
329
333
|
log.error(`Test Failure: ${error}`);
|
package/compliance-report.json
DELETED
package/compliance-report.txt
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
---------------------------------------------------------------------------------------------
|
|
2
|
-
**** Project Compliance Summary ****
|
|
3
|
-
0 project(s) are not valid
|
|
4
|
-
0 project(s) are valid
|
|
5
|
-
---------------------------------------------------------------------------------------------
|