@itentialopensource/adapter-amazon_route53 0.3.8 → 0.4.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/BROKER.md +31 -19
- package/CALLS.md +2 -2
- package/CHANGELOG.md +16 -0
- package/PROPERTIES.md +5 -0
- package/README.md +60 -63
- package/SYSTEMINFO.md +4 -1
- package/TAB1.md +13 -0
- package/TAB2.md +369 -0
- package/metadata.json +13 -2
- package/package.json +7 -9
- package/propertiesSchema.json +5 -0
- package/refs?service=git-upload-pack +0 -0
- package/report/adapterInfo.json +4 -4
- package/report/updateReport1717535007617.json +120 -0
- package/sampleProperties.json +37 -25
- package/test/integration/adapterTestIntegration.js +1 -0
- package/test/unit/adapterTestUnit.js +2 -4
package/BROKER.md
CHANGED
|
@@ -22,18 +22,25 @@ Below is an example of how you may set up the properties for this call.
|
|
|
22
22
|
{
|
|
23
23
|
"path": "/{org}/get/devices",
|
|
24
24
|
"method": "GET",
|
|
25
|
+
"pagination": {
|
|
26
|
+
"offsetVar": "",
|
|
27
|
+
"limitVar": "",
|
|
28
|
+
"incrementBy": "limit",
|
|
29
|
+
"requestLocation": "query"
|
|
30
|
+
},
|
|
25
31
|
"query": {},
|
|
26
32
|
"body": {},
|
|
27
33
|
"headers": {},
|
|
28
34
|
"handleFailure": "ignore",
|
|
35
|
+
"responseDataKey": "",
|
|
29
36
|
"requestFields": {
|
|
30
37
|
"org": "555"
|
|
31
38
|
},
|
|
32
39
|
"responseFields": {
|
|
33
|
-
"name": "
|
|
34
|
-
"ostype": "
|
|
40
|
+
"name": "{hostField}",
|
|
41
|
+
"ostype": "{osField}",
|
|
35
42
|
"ostypePrefix": "system-",
|
|
36
|
-
"ipaddress": "attributes.ipaddr",
|
|
43
|
+
"ipaddress": "{attributes.ipaddr}",
|
|
37
44
|
"port": "443"
|
|
38
45
|
}
|
|
39
46
|
},
|
|
@@ -44,16 +51,17 @@ Below is an example of how you may set up the properties for this call.
|
|
|
44
51
|
"body": {},
|
|
45
52
|
"headers": {},
|
|
46
53
|
"handleFailure": "ignore",
|
|
54
|
+
"responseDataKey": "",
|
|
47
55
|
"requestFields": {
|
|
48
56
|
"org": "777"
|
|
49
57
|
},
|
|
50
58
|
"responseFields": {
|
|
51
|
-
"name": "
|
|
52
|
-
"ostype": "
|
|
59
|
+
"name": "{hostField}",
|
|
60
|
+
"ostype": "{osField}",
|
|
53
61
|
"ostypePrefix": "system-",
|
|
54
|
-
"ipaddress": "attributes.ipaddr",
|
|
62
|
+
"ipaddress": "{attributes.ipaddr}",
|
|
55
63
|
"port": "443",
|
|
56
|
-
"myorg": "
|
|
64
|
+
"myorg": "{orgField}"
|
|
57
65
|
}
|
|
58
66
|
}
|
|
59
67
|
]
|
|
@@ -88,12 +96,13 @@ Below is an example of how you may set up the properties for this call.
|
|
|
88
96
|
"headers": {},
|
|
89
97
|
"handleFailure": "ignore",
|
|
90
98
|
"statusValue": "online",
|
|
99
|
+
"responseDataKey": "",
|
|
91
100
|
"requestFields": {
|
|
92
|
-
"org": "myorg",
|
|
93
|
-
"id": "name"
|
|
101
|
+
"org": "{myorg}",
|
|
102
|
+
"id": "{name}"
|
|
94
103
|
},
|
|
95
104
|
"responseFields": {
|
|
96
|
-
"status": "status"
|
|
105
|
+
"status": "{status}"
|
|
97
106
|
}
|
|
98
107
|
}
|
|
99
108
|
]
|
|
@@ -129,9 +138,10 @@ Below is an example of how you may set up the properties for this call.
|
|
|
129
138
|
"body": {},
|
|
130
139
|
"headers": {},
|
|
131
140
|
"handleFailure": "ignore",
|
|
141
|
+
"responseDataKey": "",
|
|
132
142
|
"requestFields": {
|
|
133
|
-
"org": "myorg",
|
|
134
|
-
"id": "name"
|
|
143
|
+
"org": "{myorg}",
|
|
144
|
+
"id": "{name}"
|
|
135
145
|
}
|
|
136
146
|
"responseFields": {}
|
|
137
147
|
},
|
|
@@ -142,8 +152,9 @@ Below is an example of how you may set up the properties for this call.
|
|
|
142
152
|
"body": {},
|
|
143
153
|
"headers": {},
|
|
144
154
|
"handleFailure": "ignore",
|
|
155
|
+
"responseDataKey": "",
|
|
145
156
|
"requestFields": {
|
|
146
|
-
"org": "myorg"
|
|
157
|
+
"org": "{myorg}"
|
|
147
158
|
}
|
|
148
159
|
"responseFields": {}
|
|
149
160
|
}
|
|
@@ -178,17 +189,18 @@ Below is an example of how you may set up the properties for this call.
|
|
|
178
189
|
"body": {},
|
|
179
190
|
"headers": {},
|
|
180
191
|
"handleFailure": "ignore",
|
|
192
|
+
"responseDataKey": "",
|
|
181
193
|
"requestFields": {
|
|
182
|
-
"org": "myorg",
|
|
183
|
-
"id": "name"
|
|
194
|
+
"org": "{myorg}",
|
|
195
|
+
"id": "{name}"
|
|
184
196
|
},
|
|
185
197
|
"responseFields": {
|
|
186
|
-
"name": "
|
|
187
|
-
"ostype": "
|
|
198
|
+
"name": "{hostField}",
|
|
199
|
+
"ostype": "{osField}",
|
|
188
200
|
"ostypePrefix": "system-",
|
|
189
|
-
"ipaddress": "attributes.ipaddr",
|
|
201
|
+
"ipaddress": "{attributes.ipaddr}",
|
|
190
202
|
"port": "443",
|
|
191
|
-
"myorg": "
|
|
203
|
+
"myorg": "{orgField}"
|
|
192
204
|
}
|
|
193
205
|
}
|
|
194
206
|
]
|
package/CALLS.md
CHANGED
|
@@ -19,7 +19,7 @@ These are adapter methods that IAP or you might use. There are some other method
|
|
|
19
19
|
</tr>
|
|
20
20
|
<tr>
|
|
21
21
|
<td style="padding:15px">healthCheck(callback)</td>
|
|
22
|
-
<td style="padding:15px">This call ensures that the adapter can communicate with Adapter for
|
|
22
|
+
<td style="padding:15px">This call ensures that the adapter can communicate with Adapter for Amazon Route 53. The actual call that is used is defined in the adapter properties and .system entities action.json file.</td>
|
|
23
23
|
<td style="padding:15px">No</td>
|
|
24
24
|
</tr>
|
|
25
25
|
<tr>
|
|
@@ -29,7 +29,7 @@ These are adapter methods that IAP or you might use. There are some other method
|
|
|
29
29
|
</tr>
|
|
30
30
|
<tr>
|
|
31
31
|
<td style="padding:15px">encryptProperty(property, technique, callback)</td>
|
|
32
|
-
<td style="padding:15px">This call will take the provided property and technique, and return the property encrypted with the technique. This allows the property to be used in the adapterProps section for the credential password so that the password does not have to be in clear text. The adapter will decrypt the property as needed for communications with Adapter for
|
|
32
|
+
<td style="padding:15px">This call will take the provided property and technique, and return the property encrypted with the technique. This allows the property to be used in the adapterProps section for the credential password so that the password does not have to be in clear text. The adapter will decrypt the property as needed for communications with Adapter for Amazon Route 53.</td>
|
|
33
33
|
<td style="padding:15px">No</td>
|
|
34
34
|
</tr>
|
|
35
35
|
<tr>
|
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,20 @@
|
|
|
1
1
|
|
|
2
|
+
## 0.4.0 [07-08-2024]
|
|
3
|
+
|
|
4
|
+
* Minor/2024 auto migration
|
|
5
|
+
|
|
6
|
+
See merge request itentialopensource/adapters/cloud/adapter-amazon_route53!16
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## 0.3.9 [03-28-2024]
|
|
11
|
+
|
|
12
|
+
* Changes made at 2024.03.28_13:14PM
|
|
13
|
+
|
|
14
|
+
See merge request itentialopensource/adapters/cloud/adapter-amazon_route53!15
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
2
18
|
## 0.3.8 [03-21-2024]
|
|
3
19
|
|
|
4
20
|
* Changes made at 2024.03.21_13:49PM
|
package/PROPERTIES.md
CHANGED
|
@@ -97,6 +97,7 @@ This section defines **all** the properties that are available for the adapter,
|
|
|
97
97
|
}
|
|
98
98
|
},
|
|
99
99
|
"devicebroker": {
|
|
100
|
+
"enabled": false,
|
|
100
101
|
"getDevice": [
|
|
101
102
|
{
|
|
102
103
|
"path": "/call/to/get/device/details",
|
|
@@ -580,6 +581,10 @@ The device broker section defines the properties used integrate Amazon_route53 t
|
|
|
580
581
|
<th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
|
|
581
582
|
<th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
|
|
582
583
|
</tr>
|
|
584
|
+
<tr>
|
|
585
|
+
<td style="padding:15px">enabled</td>
|
|
586
|
+
<td style="padding:15px">Whether or not the device broker calls have been mapped.</td>
|
|
587
|
+
</tr>
|
|
583
588
|
<tr>
|
|
584
589
|
<td style="padding:15px">getDevice</td>
|
|
585
590
|
<td style="padding:15px">The array of calls used to get device details for the broker</td>
|
package/README.md
CHANGED
|
@@ -4,29 +4,49 @@
|
|
|
4
4
|
|
|
5
5
|
Some of the page links in this document and links to other GitLab files do not work in Confluence however, the information is available in other sections of the Confluence material.
|
|
6
6
|
|
|
7
|
-
- [
|
|
8
|
-
- [Versioning](#versioning)
|
|
9
|
-
- [Supported IAP Versions](#supported-iap-versions)
|
|
10
|
-
- [Getting Started](#getting-started)
|
|
11
|
-
- [Helpful Background Information](#helpful-background-information)
|
|
12
|
-
- [Prerequisites](#prerequisites)
|
|
13
|
-
- [How to Install](#how-to-install)
|
|
14
|
-
- [Testing](#testing)
|
|
15
|
-
- [Configuration](./PROPERTIES.md)
|
|
16
|
-
- [Using this Adapter](./CALLS.md)
|
|
7
|
+
- [Specific to this Adapter](#specific-to-this-adapter)
|
|
17
8
|
- [Authentication](./AUTH.md)
|
|
18
|
-
- [
|
|
19
|
-
- [
|
|
20
|
-
- [
|
|
21
|
-
|
|
22
|
-
- [
|
|
23
|
-
- [
|
|
24
|
-
- [
|
|
25
|
-
- [
|
|
9
|
+
- [Sample Properties](./sampleProperties.json)
|
|
10
|
+
- [Available Calls](./CALLS.md)
|
|
11
|
+
- [Swagger](./report/adapter-openapi.json)
|
|
12
|
+
- [Generic Adapter Information](#generic-adapter-information)
|
|
13
|
+
- [Overview](./SUMMARY.md)
|
|
14
|
+
- [Versioning](#versioning)
|
|
15
|
+
- [Supported IAP Versions](#supported-iap-versions)
|
|
16
|
+
- [Getting Started](#getting-started)
|
|
17
|
+
- [Helpful Background Information](#helpful-background-information)
|
|
18
|
+
- [Prerequisites](#prerequisites)
|
|
19
|
+
- [How to Install](#how-to-install)
|
|
20
|
+
- [Testing](#testing)
|
|
21
|
+
- [Configuration](./PROPERTIES.md)
|
|
22
|
+
- [Additional Information](#additional-information)
|
|
23
|
+
- [Enhancements](./ENHANCE.md)
|
|
24
|
+
- [Contributing](./CONTRIBUTING.md)
|
|
25
|
+
- [Helpful Links](#helpful-links)
|
|
26
|
+
- [Node Scripts](#node-scripts)
|
|
27
|
+
- [Troubleshoot](./TROUBLESHOOT.md)
|
|
28
|
+
- [License and Maintainers](#license-and-maintainers)
|
|
29
|
+
- [Product License](#product-license)
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
## Specific to this Adapter
|
|
26
33
|
|
|
27
|
-
|
|
34
|
+
### [Authentication](./AUTH.md)
|
|
35
|
+
|
|
36
|
+
### [Sample Properties](./sampleProperties.json)
|
|
37
|
+
|
|
38
|
+
<a href="./sampleProperties.json" target="_blank">Sample Properties</a> can be used to help you configure the adapter in the Itential Automation Platform. You will need to update connectivity information such as the host, port, protocol and credentials.
|
|
39
|
+
|
|
40
|
+
### [Available Calls](./CALLS.md)
|
|
41
|
+
|
|
42
|
+
### [Swagger](./report/adapter-openapi.json)
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
## Generic Adapter Information
|
|
28
46
|
|
|
29
|
-
|
|
47
|
+
### [Overview](./SUMMARY.md)
|
|
48
|
+
|
|
49
|
+
### Versioning
|
|
30
50
|
|
|
31
51
|
Itential Product and opensource adapters utilize SemVer for versioning. The current version of the adapter can be found in the `package.json` file or viewed in the IAP GUI on the System page. All Itential opensource adapters can be found in the <a href="https://gitlab.com/itentialopensource/adapters" target="_blank">Itential OpenSource Repository</a>.
|
|
32
52
|
|
|
@@ -34,7 +54,7 @@ Any release prior to 1.0.0 is a pre-release. Initial builds of adapters are gene
|
|
|
34
54
|
|
|
35
55
|
Release notes can be viewed in CHANGELOG.md.
|
|
36
56
|
|
|
37
|
-
|
|
57
|
+
### Supported IAP Versions
|
|
38
58
|
|
|
39
59
|
Itential Product adapters are built for particular versions of IAP and packaged with the versions they work with.
|
|
40
60
|
|
|
@@ -42,11 +62,11 @@ Itential opensource adapter as well as custom adapters built with the Itential A
|
|
|
42
62
|
|
|
43
63
|
Many of the scripts that come with all adapters built using the Itential Adapter Builder do have some dependencies on IAP or the IAP database schema and so it is possible these scripts could stop working in different versions of IAP. If you notify Itential of any issues, the Adapter Team will attempt to fix the scripts for newer releases of IAP.
|
|
44
64
|
|
|
45
|
-
|
|
65
|
+
### Getting Started
|
|
46
66
|
|
|
47
67
|
These instructions will help you get a copy of the project on your local machine for development and testing. Reading this section is also helpful for deployments as it provides you with pertinent information on prerequisites and properties.
|
|
48
68
|
|
|
49
|
-
|
|
69
|
+
#### Helpful Background Information
|
|
50
70
|
|
|
51
71
|
There is <a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter documentation available on the Itential Documentation Site</a>. This documentation includes information and examples that are helpful for:
|
|
52
72
|
|
|
@@ -67,7 +87,7 @@ Troubleshooting an Adapter
|
|
|
67
87
|
Others will be added over time.
|
|
68
88
|
Want to build a new adapter? Use the <a href="https://adapters.itential.io" target="_blank">Itential Adapter Builder</a>
|
|
69
89
|
|
|
70
|
-
|
|
90
|
+
#### Prerequisites
|
|
71
91
|
|
|
72
92
|
The following is a list of required packages for installation on the system the adapter will run on:
|
|
73
93
|
|
|
@@ -154,7 +174,7 @@ eslint-plugin-json
|
|
|
154
174
|
testdouble
|
|
155
175
|
```
|
|
156
176
|
|
|
157
|
-
|
|
177
|
+
#### How to Install
|
|
158
178
|
|
|
159
179
|
1. Set up the name space location in your IAP node_modules.
|
|
160
180
|
|
|
@@ -167,8 +187,8 @@ if the @itentialopensource directory does not exist, create it:
|
|
|
167
187
|
2. Clone/unzip/tar the adapter into your IAP environment.
|
|
168
188
|
|
|
169
189
|
```bash
|
|
170
|
-
cd
|
|
171
|
-
git clone git@gitlab.com
|
|
190
|
+
cd @itentialopensource
|
|
191
|
+
git clone git@gitlab.com:@itentialopensource/adapters/adapter-amazon_route53
|
|
172
192
|
or
|
|
173
193
|
unzip adapter-amazon_route53.zip
|
|
174
194
|
or
|
|
@@ -196,30 +216,11 @@ systemctl restart pronghorn
|
|
|
196
216
|
|
|
197
217
|
7. Change the adapter service instance configuration (host, port, credentials, etc) in IAP Admin Essentials GUI
|
|
198
218
|
|
|
199
|
-
|
|
200
|
-
For an easier install of the adapter use npm run adapter:install, it will install the adapter in IAP. Please note that it can be dependent on where the adapter is installed and on the version of IAP so it is subject to fail. If using this, you can replace step 3-5 above with these:
|
|
201
|
-
|
|
202
|
-
3. Install adapter dependencies and check the adapter.
|
|
203
|
-
|
|
204
|
-
```bash
|
|
205
|
-
cd adapter-amazon_route53
|
|
206
|
-
npm run adapter:install
|
|
207
|
-
```
|
|
208
|
-
|
|
209
|
-
4. Restart IAP
|
|
210
|
-
|
|
211
|
-
```bash
|
|
212
|
-
systemctl restart pronghorn
|
|
213
|
-
```
|
|
214
|
-
|
|
215
|
-
5. Change the adapter service instance configuration (host, port, credentials, etc) in IAP Admin Essentials GUI
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
### Testing
|
|
219
|
+
#### Testing
|
|
219
220
|
|
|
220
221
|
Mocha is generally used to test all Itential Opensource Adapters. There are unit tests as well as integration tests performed. Integration tests can generally be run as standalone using mock data and running the adapter in stub mode, or as integrated. When running integrated, every effort is made to prevent environmental failures, however there is still a possibility.
|
|
221
222
|
|
|
222
|
-
|
|
223
|
+
##### Unit Testing
|
|
223
224
|
|
|
224
225
|
Unit Testing includes testing basic adapter functionality as well as error conditions that are triggered in the adapter prior to any integration. There are two ways to run unit tests. The prefered method is to use the testRunner script; however, both methods are provided here.
|
|
225
226
|
|
|
@@ -232,7 +233,7 @@ npm run test:baseunit
|
|
|
232
233
|
|
|
233
234
|
To add new unit tests, edit the `test/unit/adapterTestUnit.js` file. The tests that are already in this file should provide guidance for adding additional tests.
|
|
234
235
|
|
|
235
|
-
|
|
236
|
+
##### Integration Testing - Standalone
|
|
236
237
|
|
|
237
238
|
Standalone Integration Testing requires mock data to be provided with the entities. If this data is not provided, standalone integration testing will fail. When the adapter is set to run in stub mode (setting the stub property to true), the adapter will run through its code up to the point of making the request. It will then retrieve the mock data and return that as if it had received that data as the response from Amazon_route53. It will then translate the data so that the adapter can return the expected response to the rest of the Itential software. Standalone is the default integration test.
|
|
238
239
|
|
|
@@ -247,7 +248,7 @@ npm run test:integration
|
|
|
247
248
|
|
|
248
249
|
To add new integration tests, edit the `test/integration/adapterTestIntegration.js` file. The tests that are already in this file should provide guidance for adding additional tests.
|
|
249
250
|
|
|
250
|
-
|
|
251
|
+
##### Integration Testing
|
|
251
252
|
|
|
252
253
|
Integration Testing requires connectivity to Amazon_route53. By using the testRunner script it prevents you from having to edit the integration test. It also resets the integration test after the test is complete so that credentials are not saved in the file.
|
|
253
254
|
|
|
@@ -263,23 +264,19 @@ Test should also be written to clean up after themselves. However, it is importa
|
|
|
263
264
|
|
|
264
265
|
> **Reminder**: Do not check in code with actual credentials to systems.
|
|
265
266
|
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
## [Using this Adapter](./CALLS.md)
|
|
269
|
-
|
|
270
|
-
### [Authentication](./AUTH.md)
|
|
267
|
+
### [Configuration](./PROPERTIES.md)
|
|
271
268
|
|
|
272
|
-
|
|
269
|
+
### Additional Information
|
|
273
270
|
|
|
274
|
-
|
|
271
|
+
#### [Enhancements](./ENHANCE.md)
|
|
275
272
|
|
|
276
|
-
|
|
273
|
+
#### [Contributing](./CONTRIBUTING.md)
|
|
277
274
|
|
|
278
|
-
|
|
275
|
+
#### Helpful Links
|
|
279
276
|
|
|
280
277
|
<a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter Technical Resources</a>
|
|
281
278
|
|
|
282
|
-
|
|
279
|
+
#### Node Scripts
|
|
283
280
|
|
|
284
281
|
There are several node scripts that now accompany the adapter. These scripts are provided to make several activities easier. Many of these scripts can have issues with different versions of IAP as they have dependencies on IAP and Mongo. If you have issues with the scripts please report them to the Itential Adapter Team. Each of these scripts are described below.
|
|
285
282
|
|
|
@@ -331,9 +328,9 @@ There are several node scripts that now accompany the adapter. These scripts are
|
|
|
331
328
|
</table>
|
|
332
329
|
<br>
|
|
333
330
|
|
|
334
|
-
|
|
331
|
+
### [Troubleshoot](./TROUBLESHOOT.md)
|
|
335
332
|
|
|
336
|
-
|
|
333
|
+
### License and Maintainers
|
|
337
334
|
|
|
338
335
|
```text
|
|
339
336
|
Itential Product Adapters are maintained by the Itential Product Team.
|
|
@@ -341,6 +338,6 @@ Itential OpenSource Adapters are maintained by the Itential Adapter Team and the
|
|
|
341
338
|
Custom Adapters are maintained by other sources.
|
|
342
339
|
```
|
|
343
340
|
|
|
344
|
-
|
|
341
|
+
### Product License
|
|
345
342
|
|
|
346
343
|
[Apache 2.0](./LICENSE)
|
package/SYSTEMINFO.md
CHANGED
|
@@ -7,7 +7,7 @@ Product: Route53
|
|
|
7
7
|
Product Page: https://aws.amazon.com/route53/
|
|
8
8
|
|
|
9
9
|
## Introduction
|
|
10
|
-
We classify AWS Route53 into the Cloud domain as Route53 provides
|
|
10
|
+
We classify AWS Route53 into the Cloud domain as Route53 provides capabilities in managing and orchestrating domain name system sercices within cloud environments.
|
|
11
11
|
|
|
12
12
|
"Route53 offers Domain Name Services (DNS)"
|
|
13
13
|
"Route53 allows for customizing Domain Name Services to improve application availability"
|
|
@@ -16,6 +16,9 @@ We classify AWS Route53 into the Cloud domain as Route53 provides Cloud Services
|
|
|
16
16
|
The AWS route53 adapter from Itential is used to integrate the Itential Automation Platform (IAP) with AWS Route53. With this adapter you have the ability to perform operations such as:
|
|
17
17
|
|
|
18
18
|
- Configure and Manage DNS.
|
|
19
|
+
- Get, or Create Traffic Policy
|
|
20
|
+
- Get, Create, or Delete Hosted Zone
|
|
21
|
+
- List Hosted Zones
|
|
19
22
|
|
|
20
23
|
## Additional Product Documentation
|
|
21
24
|
The [API documents for AWS Route53](https://docs.aws.amazon.com/Route53/latest/APIReference/Welcome.html)
|
package/TAB1.md
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# Overview
|
|
2
|
+
|
|
3
|
+
This adapter is used to integrate the Itential Automation Platform (IAP) with the Amazon_route53 System. The API that was used to build the adapter for Amazon_route53 is usually available in the report directory of this adapter. The adapter utilizes the Amazon_route53 API to provide the integrations that are deemed pertinent to IAP. The ReadMe file is intended to provide information on this adapter it is generated from various other Markdown files.
|
|
4
|
+
|
|
5
|
+
## Details
|
|
6
|
+
The AWS route53 adapter from Itential is used to integrate the Itential Automation Platform (IAP) with AWS Route53. With this adapter you have the ability to perform operations such as:
|
|
7
|
+
|
|
8
|
+
- Configure and Manage DNS.
|
|
9
|
+
- Get, or Create Traffic Policy
|
|
10
|
+
- Get, Create, or Delete Hosted Zone
|
|
11
|
+
- List Hosted Zones
|
|
12
|
+
|
|
13
|
+
For further technical details on how to install and use this adapter, please click the Technical Documentation tab.
|
package/TAB2.md
ADDED
|
@@ -0,0 +1,369 @@
|
|
|
1
|
+
# Amazon Route53
|
|
2
|
+
|
|
3
|
+
## Table of Contents
|
|
4
|
+
|
|
5
|
+
- [Specific Adapter Information](#specific-adapter-information)
|
|
6
|
+
- [Authentication](#authentication)
|
|
7
|
+
- [Sample Properties](#sample-properties)
|
|
8
|
+
- [Swagger](#swagger)
|
|
9
|
+
- [Generic Adapter Information](#generic-adapter-information)
|
|
10
|
+
|
|
11
|
+
## Specific Adapter Information
|
|
12
|
+
### Authentication
|
|
13
|
+
|
|
14
|
+
This document will go through the steps for authenticating the Amazon Route53 adapter with AWS Authentication. Properly configuring the properties for an adapter in IAP is critical for getting the adapter online. You can read more about adapter authentication <a href="https://docs.itential.com/opensource/docs/authentication" target="_blank">HERE</a>.
|
|
15
|
+
|
|
16
|
+
#### AWS Authentication
|
|
17
|
+
The Amazon Route53 adapter requires AWS Authentication it does not utilize any of the autnetication methods provided by the adapter library as a result, the auth_method should be set to no_authentication. The adapter utilizes AWS signature 4 authentication. There are 3 flavors of doing this.
|
|
18
|
+
|
|
19
|
+
The first way is using a "service" account and its AWS keys to authentication as that account. In this case, you will get the aws_access_key, aws_secret_key, and aws_session_token from AWS and configure them into the adapter service instance as shown below.
|
|
20
|
+
|
|
21
|
+
The second way is using AWS STS. this still requires a "service" account and its AWS keys to authentication as that account. In this case, you will get the aws_access_key, aws_secret_key, and aws_session_token from AWS and configure them into the adapter service instance as shown below. In addition, you will provide STS paramaters in the workflow tasks that tell the adapter the role you want used on the particular call.
|
|
22
|
+
|
|
23
|
+
The third authentication method is to use an IAM role. With this method, you do not need any authentication keys as the adapter will utilize an "internal" AWS call to get the things that it needs for authentication. Since the adapter needs to make the call to this "internal" AWS IP address, the IAP server needs to be where it has access to that address or you will not be able to use this method.
|
|
24
|
+
|
|
25
|
+
If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
|
|
26
|
+
|
|
27
|
+
#### AWS Signature 4 Service Account Authentication
|
|
28
|
+
The Amazon Route53 adapter requires AWS Signature 4 Authentication. If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
|
|
29
|
+
|
|
30
|
+
This authentication is done in the adapter itself and not in the adapter libraries. This is why the auth_method is set to "no_authentication".
|
|
31
|
+
|
|
32
|
+
STEPS
|
|
33
|
+
1. Ensure you have access to a Amazon Route53 server and that it is running
|
|
34
|
+
2. Follow the steps in the README.md to import the adapter into IAP if you have not already done so
|
|
35
|
+
3. Use the properties below for the ```properties.authentication``` field
|
|
36
|
+
```json
|
|
37
|
+
"authentication": {
|
|
38
|
+
"auth_method": "aws_authentication",
|
|
39
|
+
"aws_access_key": "aws_access_key",
|
|
40
|
+
"aws_secret_key": "aws_secret_key",
|
|
41
|
+
"aws_session_token": "aws_session_token"
|
|
42
|
+
}
|
|
43
|
+
```
|
|
44
|
+
you can leave all of the other properties in the authentication section, they will not be used for Amazon Route53 authentication.
|
|
45
|
+
4. Restart the adapter. If your properties were set correctly, the adapter should go online.
|
|
46
|
+
|
|
47
|
+
#### AWS Security Token Service
|
|
48
|
+
The Amazon Route53 adapter also supports AWS Security Token Service (STS) Authentication. For using this authentication, you need to use the calls in the Adapter that have the STSRole suffix on them and pass the STS information into the method.
|
|
49
|
+
|
|
50
|
+
#### AWS IAM Role
|
|
51
|
+
The Amazon Route53 adapter also supports AWS IAM Role Authentication. For using this authentication, you need to use the calls in the Adapter that have the STSRole suffix on them and pass the RoleName into the method.
|
|
52
|
+
|
|
53
|
+
#### AMAZON STEPS FOR IAM ROLE
|
|
54
|
+
Increase number of hops if running IAP inside of docker on EC2 instance
|
|
55
|
+
```bash
|
|
56
|
+
aws sso login --profile aws-bota-1
|
|
57
|
+
<export aws keys for CLI access>
|
|
58
|
+
|
|
59
|
+
aws ec2 modify-instance-metadata-options --instance-id i-0e150236026b7c45d --http-put-response-hop-limit 3 --http-endpoint enabled --region us-east-1
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
Create a new role and attach to it policies:
|
|
63
|
+
- go to your EC2 instance, select it
|
|
64
|
+
- Actions->Security->Modify IAM Role
|
|
65
|
+
- Click 'Create New IAM Role'
|
|
66
|
+
- Create a role:
|
|
67
|
+
```text
|
|
68
|
+
Trusted entity type: AWS service
|
|
69
|
+
Use Case: EC2
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
Add policies to the role
|
|
73
|
+
- AmazonEC2FullAccess (Provides full access to Amazon EC2 via the AWS Management Console.)
|
|
74
|
+
- AmazonRoute53FullAccess (Provides full access to all Amazon Route 53 via the AWS Management Console.)
|
|
75
|
+
|
|
76
|
+
Save the role
|
|
77
|
+
|
|
78
|
+
Go back to your EC2 instance and Actions->Security->Modify IAM Role, associate newly created role with your EC2 instance
|
|
79
|
+
|
|
80
|
+
#### Troubleshooting
|
|
81
|
+
- Make sure you copied over the correct access key, secret key and session token.
|
|
82
|
+
- Turn on debug level logs for the adapter in IAP Admin Essentials.
|
|
83
|
+
- Turn on auth_logging for the adapter in IAP Admin Essentials (adapter properties).
|
|
84
|
+
- Investigate the logs - in particular:
|
|
85
|
+
- The FULL REQUEST log to make sure the proper headers are being sent with the request.
|
|
86
|
+
- The FULL BODY log to make sure the payload is accurate.
|
|
87
|
+
- The CALL RETURN log to see what the other system is telling us.
|
|
88
|
+
- Credentials should be ** masked ** by the adapter so make sure you verify the username and password - including that there are erroneous spaces at the front or end.
|
|
89
|
+
- Remember when you are done to turn auth_logging off as you do not want to log credentials.
|
|
90
|
+
- For IAM, you can run this on the IAP server to verify you are getting to the "internal" AWS Server
|
|
91
|
+
```bash
|
|
92
|
+
TOKEN=`curl -v -X PUT "http://169.254.169.254/latest/api/token" -H "X-aws-ec2-metadata-token-ttl-seconds: 21600"` && curl -v -H "X-aws-ec2-metadata-token: $TOKEN" -v http://169.254.169.254/latest/meta-data/iam/security-credentials/<rolename>
|
|
93
|
+
```
|
|
94
|
+
### Sample Properties
|
|
95
|
+
|
|
96
|
+
Sample Properties can be used to help you configure the adapter in the Itential Automation Platform. You will need to update connectivity information such as the host, port, protocol and credentials.
|
|
97
|
+
|
|
98
|
+
```json
|
|
99
|
+
"properties": {
|
|
100
|
+
"host": "localhost",
|
|
101
|
+
"region": "us-east-1",
|
|
102
|
+
"port": 443,
|
|
103
|
+
"choosepath": "",
|
|
104
|
+
"base_path": "/",
|
|
105
|
+
"version": "2013-04-01",
|
|
106
|
+
"service": "route53",
|
|
107
|
+
"cache_location": "none",
|
|
108
|
+
"encode_pathvars": true,
|
|
109
|
+
"encode_queryvars": true,
|
|
110
|
+
"save_metric": false,
|
|
111
|
+
"stub": true,
|
|
112
|
+
"protocol": "https",
|
|
113
|
+
"authentication": {
|
|
114
|
+
"auth_method": "aws_authentication",
|
|
115
|
+
"username": "username",
|
|
116
|
+
"password": "password",
|
|
117
|
+
"token": "token",
|
|
118
|
+
"token_timeout": 600000,
|
|
119
|
+
"token_cache": "local",
|
|
120
|
+
"invalid_token_error": 401,
|
|
121
|
+
"auth_field": "header.headers.Authorization",
|
|
122
|
+
"auth_field_format": "Basic {b64}{username}:{password}{/b64}",
|
|
123
|
+
"auth_logging": false,
|
|
124
|
+
"client_id": "",
|
|
125
|
+
"client_secret": "",
|
|
126
|
+
"grant_type": "",
|
|
127
|
+
"sensitive": [],
|
|
128
|
+
"sso": {
|
|
129
|
+
"protocol": "",
|
|
130
|
+
"host": "",
|
|
131
|
+
"port": 0
|
|
132
|
+
},
|
|
133
|
+
"multiStepAuthCalls": [
|
|
134
|
+
{
|
|
135
|
+
"name": "",
|
|
136
|
+
"requestFields": {},
|
|
137
|
+
"responseFields": {},
|
|
138
|
+
"successfullResponseCode": 200
|
|
139
|
+
}
|
|
140
|
+
],
|
|
141
|
+
"aws_access_key": "aws_access_key",
|
|
142
|
+
"aws_secret_key": "aws_secret_key",
|
|
143
|
+
"aws_session_token": "aws_session_token",
|
|
144
|
+
"aws_iam_role": ""
|
|
145
|
+
},
|
|
146
|
+
"healthcheck": {
|
|
147
|
+
"type": "startup",
|
|
148
|
+
"frequency": 60000,
|
|
149
|
+
"query_object": {},
|
|
150
|
+
"addlHeaders": {}
|
|
151
|
+
},
|
|
152
|
+
"throttle": {
|
|
153
|
+
"throttle_enabled": false,
|
|
154
|
+
"number_pronghorns": 1,
|
|
155
|
+
"sync_async": "sync",
|
|
156
|
+
"max_in_queue": 1000,
|
|
157
|
+
"concurrent_max": 1,
|
|
158
|
+
"expire_timeout": 0,
|
|
159
|
+
"avg_runtime": 200,
|
|
160
|
+
"priorities": [
|
|
161
|
+
{
|
|
162
|
+
"value": 0,
|
|
163
|
+
"percent": 100
|
|
164
|
+
}
|
|
165
|
+
]
|
|
166
|
+
},
|
|
167
|
+
"request": {
|
|
168
|
+
"number_redirects": 0,
|
|
169
|
+
"number_retries": 3,
|
|
170
|
+
"limit_retry_error": [
|
|
171
|
+
0
|
|
172
|
+
],
|
|
173
|
+
"failover_codes": [],
|
|
174
|
+
"attempt_timeout": 5000,
|
|
175
|
+
"global_request": {
|
|
176
|
+
"payload": {},
|
|
177
|
+
"uriOptions": {},
|
|
178
|
+
"addlHeaders": {},
|
|
179
|
+
"authData": {}
|
|
180
|
+
},
|
|
181
|
+
"healthcheck_on_timeout": true,
|
|
182
|
+
"return_raw": false,
|
|
183
|
+
"archiving": false,
|
|
184
|
+
"return_request": false
|
|
185
|
+
},
|
|
186
|
+
"proxy": {
|
|
187
|
+
"enabled": false,
|
|
188
|
+
"host": "",
|
|
189
|
+
"port": 1,
|
|
190
|
+
"protocol": "http",
|
|
191
|
+
"username": "",
|
|
192
|
+
"password": ""
|
|
193
|
+
},
|
|
194
|
+
"ssl": {
|
|
195
|
+
"ecdhCurve": "",
|
|
196
|
+
"enabled": false,
|
|
197
|
+
"accept_invalid_cert": false,
|
|
198
|
+
"ca_file": "",
|
|
199
|
+
"key_file": "",
|
|
200
|
+
"cert_file": "",
|
|
201
|
+
"secure_protocol": "",
|
|
202
|
+
"ciphers": ""
|
|
203
|
+
},
|
|
204
|
+
"mongo": {
|
|
205
|
+
"host": "",
|
|
206
|
+
"port": 0,
|
|
207
|
+
"database": "",
|
|
208
|
+
"username": "",
|
|
209
|
+
"password": "",
|
|
210
|
+
"replSet": "",
|
|
211
|
+
"db_ssl": {
|
|
212
|
+
"enabled": false,
|
|
213
|
+
"accept_invalid_cert": false,
|
|
214
|
+
"ca_file": "",
|
|
215
|
+
"key_file": "",
|
|
216
|
+
"cert_file": ""
|
|
217
|
+
}
|
|
218
|
+
},
|
|
219
|
+
"devicebroker": {
|
|
220
|
+
"enabled": false,
|
|
221
|
+
"getDevice": [
|
|
222
|
+
{
|
|
223
|
+
"path": "/not/mapped",
|
|
224
|
+
"method": "GET",
|
|
225
|
+
"query": {},
|
|
226
|
+
"body": {},
|
|
227
|
+
"headers": {},
|
|
228
|
+
"handleFailure": "ignore",
|
|
229
|
+
"requestFields": {
|
|
230
|
+
"insample": "{port}"
|
|
231
|
+
},
|
|
232
|
+
"responseDatakey": "",
|
|
233
|
+
"responseFields": {
|
|
234
|
+
"name": "{this}{||}{that}",
|
|
235
|
+
"ostype": "{osfield}",
|
|
236
|
+
"ostypePrefix": "meraki-",
|
|
237
|
+
"port": "{port}",
|
|
238
|
+
"ipaddress": "{ip_addr}",
|
|
239
|
+
"serial": "{serial}"
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
],
|
|
243
|
+
"getDevicesFiltered": [
|
|
244
|
+
{
|
|
245
|
+
"path": "/not/mapped",
|
|
246
|
+
"method": "GET",
|
|
247
|
+
"pagination": {
|
|
248
|
+
"offsetVar": "",
|
|
249
|
+
"limitVar": "",
|
|
250
|
+
"incrementBy": "limit",
|
|
251
|
+
"requestLocation": "query"
|
|
252
|
+
},
|
|
253
|
+
"query": {},
|
|
254
|
+
"body": {},
|
|
255
|
+
"headers": {},
|
|
256
|
+
"handleFailure": "ignore",
|
|
257
|
+
"requestFields": {},
|
|
258
|
+
"responseDatakey": "",
|
|
259
|
+
"responseFields": {
|
|
260
|
+
"name": "{this}{||}{that}",
|
|
261
|
+
"ostype": "{osfield}",
|
|
262
|
+
"ostypePrefix": "meraki-",
|
|
263
|
+
"port": "{port}",
|
|
264
|
+
"ipaddress": "{ip_addr}",
|
|
265
|
+
"serial": "{serial}",
|
|
266
|
+
"id": "{myid}"
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
],
|
|
270
|
+
"isAlive": [
|
|
271
|
+
{
|
|
272
|
+
"path": "/not/mapped/{devID}",
|
|
273
|
+
"method": "GET",
|
|
274
|
+
"query": {},
|
|
275
|
+
"body": {},
|
|
276
|
+
"headers": {},
|
|
277
|
+
"handleFailure": "ignore",
|
|
278
|
+
"requestFields": {
|
|
279
|
+
"devID": "{id}"
|
|
280
|
+
},
|
|
281
|
+
"responseDatakey": "",
|
|
282
|
+
"responseFields": {
|
|
283
|
+
"status": "return2xx",
|
|
284
|
+
"statusValue": "AD.200"
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
],
|
|
288
|
+
"getConfig": [
|
|
289
|
+
{
|
|
290
|
+
"path": "/not/mapped/{devID}",
|
|
291
|
+
"method": "GET",
|
|
292
|
+
"query": {},
|
|
293
|
+
"body": {},
|
|
294
|
+
"headers": {},
|
|
295
|
+
"handleFailure": "ignore",
|
|
296
|
+
"requestFields": {
|
|
297
|
+
"devID": "{id}"
|
|
298
|
+
},
|
|
299
|
+
"responseDatakey": "",
|
|
300
|
+
"responseFields": {}
|
|
301
|
+
}
|
|
302
|
+
],
|
|
303
|
+
"getCount": [
|
|
304
|
+
{
|
|
305
|
+
"path": "/not/mapped",
|
|
306
|
+
"method": "GET",
|
|
307
|
+
"query": {},
|
|
308
|
+
"body": {},
|
|
309
|
+
"headers": {},
|
|
310
|
+
"handleFailure": "ignore",
|
|
311
|
+
"requestFields": {},
|
|
312
|
+
"responseDatakey": "",
|
|
313
|
+
"responseFields": {}
|
|
314
|
+
}
|
|
315
|
+
]
|
|
316
|
+
},
|
|
317
|
+
"cache": {
|
|
318
|
+
"enabled": false,
|
|
319
|
+
"entities": [
|
|
320
|
+
{
|
|
321
|
+
"entityType": "device",
|
|
322
|
+
"frequency": 3600,
|
|
323
|
+
"flushOnFail": false,
|
|
324
|
+
"limit": 10000,
|
|
325
|
+
"retryAttempts": 5,
|
|
326
|
+
"sort": true,
|
|
327
|
+
"populate": [
|
|
328
|
+
{
|
|
329
|
+
"path": "/not/mapped",
|
|
330
|
+
"method": "GET",
|
|
331
|
+
"pagination": {
|
|
332
|
+
"offsetVar": "",
|
|
333
|
+
"limitVar": "",
|
|
334
|
+
"incrementBy": "limit",
|
|
335
|
+
"requestLocation": "query"
|
|
336
|
+
},
|
|
337
|
+
"query": {},
|
|
338
|
+
"body": {},
|
|
339
|
+
"headers": {},
|
|
340
|
+
"handleFailure": "ignore",
|
|
341
|
+
"requestFields": {},
|
|
342
|
+
"responseDatakey": "",
|
|
343
|
+
"responseFields": {
|
|
344
|
+
"name": "{this}{||}{that}",
|
|
345
|
+
"ostype": "{osfield}",
|
|
346
|
+
"ostypePrefix": "meraki-",
|
|
347
|
+
"port": "{port}",
|
|
348
|
+
"ipaddress": "{ip_addr}",
|
|
349
|
+
"serial": "{serial}",
|
|
350
|
+
"id": "{myid}"
|
|
351
|
+
}
|
|
352
|
+
}
|
|
353
|
+
],
|
|
354
|
+
"cachedTasks": [
|
|
355
|
+
{
|
|
356
|
+
"name": "",
|
|
357
|
+
"filterField": "",
|
|
358
|
+
"filterLoc": ""
|
|
359
|
+
}
|
|
360
|
+
]
|
|
361
|
+
}
|
|
362
|
+
]
|
|
363
|
+
}
|
|
364
|
+
}
|
|
365
|
+
```
|
|
366
|
+
### [Swagger](https://gitlab.com/itentialopensource/adapters/cloud/adapter-amazon_route53/-/blob/master/report/adapter-openapi.json)
|
|
367
|
+
|
|
368
|
+
## [Generic Adapter Information](https://gitlab.com/itentialopensource/adapters/cloud/adapter-amazon_route53/-/blob/master/README.md)
|
|
369
|
+
|
package/metadata.json
CHANGED
|
@@ -44,13 +44,24 @@
|
|
|
44
44
|
"isDeprecated": false
|
|
45
45
|
},
|
|
46
46
|
"brokerSince": "",
|
|
47
|
+
"authMethods": [
|
|
48
|
+
{
|
|
49
|
+
"type": "AWS Auth",
|
|
50
|
+
"primary": true
|
|
51
|
+
}
|
|
52
|
+
],
|
|
47
53
|
"documentation": {
|
|
48
54
|
"storeLink": "",
|
|
49
55
|
"npmLink": "https://www.npmjs.com/package/@itentialopensource/adapter-amazon_route53",
|
|
50
|
-
"repoLink": "https://gitlab.com/itentialopensource/adapters/
|
|
56
|
+
"repoLink": "https://gitlab.com/itentialopensource/adapters/adapter-amazon_route53",
|
|
51
57
|
"docLink": "https://docs.itential.com/opensource/docs/amazon-route53",
|
|
52
58
|
"demoLinks": [],
|
|
53
|
-
"trainingLinks": [
|
|
59
|
+
"trainingLinks": [
|
|
60
|
+
{
|
|
61
|
+
"title": "Itential Academy",
|
|
62
|
+
"link": "https://www.itential.com/itential-academy/"
|
|
63
|
+
}
|
|
64
|
+
],
|
|
54
65
|
"faqLink": "https://docs.itential.com/opensource/docs/troubleshooting-an-adapter",
|
|
55
66
|
"contributeLink": "https://gitlab.com/itentialopensource/adapters/contributing-guide",
|
|
56
67
|
"issueLink": "https://itential.atlassian.net/servicedesk/customer/portals",
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itentialopensource/adapter-amazon_route53",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "This adapter integrates with system described as: Amazon Route53.",
|
|
5
5
|
"main": "adapter.js",
|
|
6
6
|
"systemName": "Amazon AWS Route53",
|
|
7
7
|
"wizardVersion": "2.44.7",
|
|
8
|
-
"engineVersion": "1.67.
|
|
8
|
+
"engineVersion": "1.67.20",
|
|
9
9
|
"adapterType": "http",
|
|
10
10
|
"scripts": {
|
|
11
11
|
"artifactize": "npm i && node utils/packModificationScript.js",
|
|
@@ -16,7 +16,6 @@
|
|
|
16
16
|
"test:baseunit": "mocha test/unit/adapterBaseTestUnit.js --LOG=error",
|
|
17
17
|
"test:unit": "mocha test/unit/adapterTestUnit.js --LOG=error",
|
|
18
18
|
"test:integration": "mocha test/integration/adapterTestIntegration.js --LOG=error",
|
|
19
|
-
"test:cover": "nyc --reporter html --reporter text mocha --reporter dot test/*",
|
|
20
19
|
"adapter:patches2bundled": "node utils/patches2bundledDeps.js",
|
|
21
20
|
"test": "npm run test:baseunit && npm run test:unit && npm run test:integration",
|
|
22
21
|
"adapter:install": "npm i && node utils/tbScript.js install",
|
|
@@ -46,20 +45,20 @@
|
|
|
46
45
|
],
|
|
47
46
|
"license": "Apache-2.0",
|
|
48
47
|
"engines": {
|
|
49
|
-
"node": ">=
|
|
48
|
+
"node": ">= 14.0.0",
|
|
50
49
|
"npm": ">= 6.0.0"
|
|
51
50
|
},
|
|
52
51
|
"repository": {
|
|
53
52
|
"type": "git",
|
|
54
|
-
"url": "git@gitlab.com:itentialopensource/adapters/
|
|
53
|
+
"url": "git@gitlab.com:itentialopensource/adapters/adapter-amazon_route53.git"
|
|
55
54
|
},
|
|
56
55
|
"author": "Itential",
|
|
57
|
-
"homepage": "https://gitlab.com/itentialopensource/adapters/
|
|
56
|
+
"homepage": "https://gitlab.com/itentialopensource/adapters/adapter-amazon_route53#readme",
|
|
58
57
|
"dependencies": {
|
|
59
|
-
"@itentialopensource/adapter-utils": "^5.
|
|
58
|
+
"@itentialopensource/adapter-utils": "^5.5.0",
|
|
60
59
|
"acorn": "^8.10.0",
|
|
61
60
|
"ajv": "^8.12.0",
|
|
62
|
-
"axios": "^1.6.
|
|
61
|
+
"axios": "^1.6.8",
|
|
63
62
|
"commander": "^11.0.0",
|
|
64
63
|
"dns-lookup-promise": "^1.0.4",
|
|
65
64
|
"fs-extra": "^11.1.1",
|
|
@@ -67,7 +66,6 @@
|
|
|
67
66
|
"mocha": "^10.3.0",
|
|
68
67
|
"mocha-param": "^2.0.1",
|
|
69
68
|
"mongodb": "^4.16.0",
|
|
70
|
-
"nyc": "^15.1.0",
|
|
71
69
|
"ping": "^0.4.4",
|
|
72
70
|
"prompts": "^2.4.2",
|
|
73
71
|
"readline-sync": "^1.4.10",
|
package/propertiesSchema.json
CHANGED
|
@@ -985,6 +985,11 @@
|
|
|
985
985
|
"devicebroker": {
|
|
986
986
|
"type": "object",
|
|
987
987
|
"properties": {
|
|
988
|
+
"enabled": {
|
|
989
|
+
"type": "boolean",
|
|
990
|
+
"description": "Whether or not the device broker calls have been mapped",
|
|
991
|
+
"default": false
|
|
992
|
+
},
|
|
988
993
|
"getDevice": {
|
|
989
994
|
"type": "array",
|
|
990
995
|
"description": "Broker call(s) to getDevice",
|
|
Binary file
|
package/report/adapterInfo.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.3.
|
|
3
|
-
"configLines":
|
|
2
|
+
"version": "0.3.9",
|
|
3
|
+
"configLines": 9898,
|
|
4
4
|
"scriptLines": 1783,
|
|
5
5
|
"codeLines": 9292,
|
|
6
|
-
"testLines":
|
|
6
|
+
"testLines": 6944,
|
|
7
7
|
"testCases": 354,
|
|
8
|
-
"totalCodeLines":
|
|
8
|
+
"totalCodeLines": 18019,
|
|
9
9
|
"wfTasks": 153
|
|
10
10
|
}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
{
|
|
2
|
+
"errors": [],
|
|
3
|
+
"statistics": [
|
|
4
|
+
{
|
|
5
|
+
"owner": "errorJson",
|
|
6
|
+
"description": "New adapter errors available for use",
|
|
7
|
+
"value": 0
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"owner": "errorJson",
|
|
11
|
+
"description": "Adapter errors no longer available for use",
|
|
12
|
+
"value": 0
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"owner": "errorJson",
|
|
16
|
+
"description": "Adapter errors that have been updated (e.g. recommendation changes)",
|
|
17
|
+
"value": 31
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"owner": "packageJson",
|
|
21
|
+
"description": "Number of production dependencies",
|
|
22
|
+
"value": 16
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"owner": "packageJson",
|
|
26
|
+
"description": "Number of development dependencies",
|
|
27
|
+
"value": 6
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"owner": "packageJson",
|
|
31
|
+
"description": "Number of npm scripts",
|
|
32
|
+
"value": 21
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"owner": "packageJson",
|
|
36
|
+
"description": "Runtime Library dependency",
|
|
37
|
+
"value": "^5.5.0"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"owner": "propertiesSchemaJson",
|
|
41
|
+
"description": "Adapter properties defined in the propertiesSchema file",
|
|
42
|
+
"value": 83
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"owner": "markdown",
|
|
46
|
+
"description": "Number of lines in the README.md",
|
|
47
|
+
"value": 344
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"owner": "markdown",
|
|
51
|
+
"description": "Number of lines in the SUMMARY.md",
|
|
52
|
+
"value": 9
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"owner": "markdown",
|
|
56
|
+
"description": "Number of lines in the PROPERTIES.md",
|
|
57
|
+
"value": 647
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"owner": "markdown",
|
|
61
|
+
"description": "Number of lines in the TROUBLESHOOT.md",
|
|
62
|
+
"value": 48
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"owner": "markdown",
|
|
66
|
+
"description": "Number of lines in the ENHANCE.md",
|
|
67
|
+
"value": 70
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"owner": "markdown",
|
|
71
|
+
"description": "Number of lines in the BROKER.md",
|
|
72
|
+
"value": 70
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"owner": "unitTestJS",
|
|
76
|
+
"description": "Number of lines of code in unit tests",
|
|
77
|
+
"value": 3584
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
"owner": "unitTestJS",
|
|
81
|
+
"description": "Number of unit tests",
|
|
82
|
+
"value": 209
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
"owner": "integrationTestJS",
|
|
86
|
+
"description": "Number of lines of code in integration tests",
|
|
87
|
+
"value": 2108
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
"owner": "integrationTestJS",
|
|
91
|
+
"description": "Number of integration tests",
|
|
92
|
+
"value": 73
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
"owner": "staticFile",
|
|
96
|
+
"description": "Number of lines of code in adapterBase.js",
|
|
97
|
+
"value": 1453
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
"owner": "staticFile",
|
|
101
|
+
"description": "Number of static files added",
|
|
102
|
+
"value": 36
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
"owner": "Overall",
|
|
106
|
+
"description": "Total lines of Code",
|
|
107
|
+
"value": 7145
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"owner": "Overall",
|
|
111
|
+
"description": "Total Tests",
|
|
112
|
+
"value": 282
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
"owner": "Overall",
|
|
116
|
+
"description": "Total Files",
|
|
117
|
+
"value": 6
|
|
118
|
+
}
|
|
119
|
+
]
|
|
120
|
+
}
|
package/sampleProperties.json
CHANGED
|
@@ -122,30 +122,32 @@
|
|
|
122
122
|
}
|
|
123
123
|
},
|
|
124
124
|
"devicebroker": {
|
|
125
|
+
"enabled": false,
|
|
125
126
|
"getDevice": [
|
|
126
127
|
{
|
|
127
|
-
"path": "/
|
|
128
|
+
"path": "/not/mapped",
|
|
128
129
|
"method": "GET",
|
|
129
130
|
"query": {},
|
|
130
131
|
"body": {},
|
|
131
132
|
"headers": {},
|
|
132
133
|
"handleFailure": "ignore",
|
|
133
134
|
"requestFields": {
|
|
134
|
-
"
|
|
135
|
+
"insample": "{port}"
|
|
135
136
|
},
|
|
136
137
|
"responseDatakey": "",
|
|
137
138
|
"responseFields": {
|
|
138
|
-
"name": "
|
|
139
|
-
"ostype": "
|
|
140
|
-
"ostypePrefix": "
|
|
141
|
-
"
|
|
142
|
-
"
|
|
139
|
+
"name": "{this}{||}{that}",
|
|
140
|
+
"ostype": "{osfield}",
|
|
141
|
+
"ostypePrefix": "meraki-",
|
|
142
|
+
"port": "{port}",
|
|
143
|
+
"ipaddress": "{ip_addr}",
|
|
144
|
+
"serial" : "{serial}"
|
|
143
145
|
}
|
|
144
146
|
}
|
|
145
147
|
],
|
|
146
148
|
"getDevicesFiltered": [
|
|
147
149
|
{
|
|
148
|
-
"path": "/
|
|
150
|
+
"path": "/not/mapped",
|
|
149
151
|
"method": "GET",
|
|
150
152
|
"pagination": {
|
|
151
153
|
"offsetVar": "",
|
|
@@ -160,42 +162,44 @@
|
|
|
160
162
|
"requestFields": {},
|
|
161
163
|
"responseDatakey": "",
|
|
162
164
|
"responseFields": {
|
|
163
|
-
"name": "
|
|
164
|
-
"ostype": "
|
|
165
|
-
"ostypePrefix": "
|
|
166
|
-
"
|
|
167
|
-
"
|
|
165
|
+
"name": "{this}{||}{that}",
|
|
166
|
+
"ostype": "{osfield}",
|
|
167
|
+
"ostypePrefix": "meraki-",
|
|
168
|
+
"port": "{port}",
|
|
169
|
+
"ipaddress": "{ip_addr}",
|
|
170
|
+
"serial" : "{serial}",
|
|
171
|
+
"id": "{myid}"
|
|
168
172
|
}
|
|
169
173
|
}
|
|
170
174
|
],
|
|
171
175
|
"isAlive": [
|
|
172
176
|
{
|
|
173
|
-
"path": "/
|
|
177
|
+
"path": "/not/mapped/{devID}",
|
|
174
178
|
"method": "GET",
|
|
175
179
|
"query": {},
|
|
176
180
|
"body": {},
|
|
177
181
|
"headers": {},
|
|
178
182
|
"handleFailure": "ignore",
|
|
179
183
|
"requestFields": {
|
|
180
|
-
"
|
|
184
|
+
"devID": "{id}"
|
|
181
185
|
},
|
|
182
186
|
"responseDatakey": "",
|
|
183
187
|
"responseFields": {
|
|
184
|
-
"status": "
|
|
185
|
-
"statusValue": "
|
|
188
|
+
"status": "return2xx",
|
|
189
|
+
"statusValue": "AD.200"
|
|
186
190
|
}
|
|
187
191
|
}
|
|
188
192
|
],
|
|
189
193
|
"getConfig": [
|
|
190
194
|
{
|
|
191
|
-
"path": "/
|
|
195
|
+
"path": "/not/mapped/{devID}",
|
|
192
196
|
"method": "GET",
|
|
193
197
|
"query": {},
|
|
194
198
|
"body": {},
|
|
195
199
|
"headers": {},
|
|
196
200
|
"handleFailure": "ignore",
|
|
197
201
|
"requestFields": {
|
|
198
|
-
"
|
|
202
|
+
"devID": "{id}"
|
|
199
203
|
},
|
|
200
204
|
"responseDatakey": "",
|
|
201
205
|
"responseFields": {}
|
|
@@ -203,7 +207,7 @@
|
|
|
203
207
|
],
|
|
204
208
|
"getCount": [
|
|
205
209
|
{
|
|
206
|
-
"path": "/
|
|
210
|
+
"path": "/not/mapped",
|
|
207
211
|
"method": "GET",
|
|
208
212
|
"query": {},
|
|
209
213
|
"body": {},
|
|
@@ -219,15 +223,15 @@
|
|
|
219
223
|
"enabled": false,
|
|
220
224
|
"entities": [
|
|
221
225
|
{
|
|
222
|
-
"entityType": "",
|
|
223
|
-
"frequency":
|
|
226
|
+
"entityType": "device",
|
|
227
|
+
"frequency": 3600,
|
|
224
228
|
"flushOnFail": false,
|
|
225
|
-
"limit":
|
|
229
|
+
"limit": 10000,
|
|
226
230
|
"retryAttempts": 5,
|
|
227
231
|
"sort": true,
|
|
228
232
|
"populate": [
|
|
229
233
|
{
|
|
230
|
-
"path": "",
|
|
234
|
+
"path": "/not/mapped",
|
|
231
235
|
"method": "GET",
|
|
232
236
|
"pagination": {
|
|
233
237
|
"offsetVar": "",
|
|
@@ -241,7 +245,15 @@
|
|
|
241
245
|
"handleFailure": "ignore",
|
|
242
246
|
"requestFields": {},
|
|
243
247
|
"responseDatakey": "",
|
|
244
|
-
"responseFields": {
|
|
248
|
+
"responseFields": {
|
|
249
|
+
"name": "{this}{||}{that}",
|
|
250
|
+
"ostype": "{osfield}",
|
|
251
|
+
"ostypePrefix": "meraki-",
|
|
252
|
+
"port": "{port}",
|
|
253
|
+
"ipaddress": "{ip_addr}",
|
|
254
|
+
"serial" : "{serial}",
|
|
255
|
+
"id": "{myid}"
|
|
256
|
+
}
|
|
245
257
|
}
|
|
246
258
|
],
|
|
247
259
|
"cachedTasks": [
|
|
@@ -46,6 +46,7 @@ samProps.ssl.accept_invalid_cert = false;
|
|
|
46
46
|
if (samProps.request.attempt_timeout < 30000) {
|
|
47
47
|
samProps.request.attempt_timeout = 30000;
|
|
48
48
|
}
|
|
49
|
+
samProps.devicebroker.enabled = true;
|
|
49
50
|
const attemptTimeout = samProps.request.attempt_timeout;
|
|
50
51
|
const { stub } = samProps;
|
|
51
52
|
|
|
@@ -284,7 +284,6 @@ describe('[unit] Amazon_route53 Adapter Test', () => {
|
|
|
284
284
|
assert.equal('mocha test/unit/adapterBaseTestUnit.js --LOG=error', packageDotJson.scripts['test:baseunit']);
|
|
285
285
|
assert.equal('mocha test/unit/adapterTestUnit.js --LOG=error', packageDotJson.scripts['test:unit']);
|
|
286
286
|
assert.equal('mocha test/integration/adapterTestIntegration.js --LOG=error', packageDotJson.scripts['test:integration']);
|
|
287
|
-
assert.equal('nyc --reporter html --reporter text mocha --reporter dot test/*', packageDotJson.scripts['test:cover']);
|
|
288
287
|
assert.equal('npm run test:baseunit && npm run test:unit && npm run test:integration', packageDotJson.scripts.test);
|
|
289
288
|
assert.equal('npm publish --registry=https://registry.npmjs.org --access=public', packageDotJson.scripts.deploy);
|
|
290
289
|
assert.equal('npm run deploy', packageDotJson.scripts.build);
|
|
@@ -316,12 +315,11 @@ describe('[unit] Amazon_route53 Adapter Test', () => {
|
|
|
316
315
|
assert.notEqual(null, packageDotJson.dependencies);
|
|
317
316
|
assert.notEqual('', packageDotJson.dependencies);
|
|
318
317
|
assert.equal('^8.12.0', packageDotJson.dependencies.ajv);
|
|
319
|
-
assert.equal('^1.6.
|
|
318
|
+
assert.equal('^1.6.8', packageDotJson.dependencies.axios);
|
|
320
319
|
assert.equal('^11.0.0', packageDotJson.dependencies.commander);
|
|
321
320
|
assert.equal('^11.1.1', packageDotJson.dependencies['fs-extra']);
|
|
322
321
|
assert.equal('^10.3.0', packageDotJson.dependencies.mocha);
|
|
323
322
|
assert.equal('^2.0.1', packageDotJson.dependencies['mocha-param']);
|
|
324
|
-
assert.equal('^15.1.0', packageDotJson.dependencies.nyc);
|
|
325
323
|
assert.equal('^0.4.4', packageDotJson.dependencies.ping);
|
|
326
324
|
assert.equal('^1.4.10', packageDotJson.dependencies['readline-sync']);
|
|
327
325
|
assert.equal('^7.5.3', packageDotJson.dependencies.semver);
|
|
@@ -563,7 +561,7 @@ describe('[unit] Amazon_route53 Adapter Test', () => {
|
|
|
563
561
|
log.error(`Adapter Exception: ${error}`);
|
|
564
562
|
done(error);
|
|
565
563
|
}
|
|
566
|
-
});
|
|
564
|
+
}).timeout(attemptTimeout);
|
|
567
565
|
});
|
|
568
566
|
|
|
569
567
|
describe('propertiesSchema.json', () => {
|