@jjrawlins/cdk-diff-pr-github-action 1.2.2 → 1.2.4
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/.jsii +3 -3
- package/lib/CdkDiffIamTemplate.js +2 -2
- package/lib/CdkDiffIamTemplateStackSet.js +2 -2
- package/lib/CdkDiffStackWorkflow.js +1 -1
- package/lib/CdkDriftDetectionWorkflow.js +1 -1
- package/lib/CdkDriftIamTemplate.js +2 -2
- package/lib/bin/cdk-changeset-script.js +1 -3
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/LICENSE +201 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/README.md +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-cjs/index.js +415 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-cjs/lib/aws/partitions.json +267 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/aws.js +10 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/index.js +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/lib/aws/index.js +3 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/lib/aws/isVirtualHostableS3Bucket.js +25 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/lib/aws/parseArn.js +18 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/lib/aws/partition.js +41 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/lib/aws/partitions.json +267 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/lib/isIpAddress.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/resolveDefaultAwsRegionalEndpointsConfig.js +21 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/resolveEndpoint.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/types/EndpointError.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/types/EndpointRuleObject.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/types/ErrorRuleObject.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/types/RuleSetObject.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/types/TreeRuleObject.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/types/index.js +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-es/types/shared.js +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/aws.d.ts +2 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/index.d.ts +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/lib/aws/index.d.ts +3 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/lib/aws/isVirtualHostableS3Bucket.d.ts +5 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/lib/aws/parseArn.d.ts +7 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/lib/aws/partition.d.ts +38 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/lib/isIpAddress.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/resolveDefaultAwsRegionalEndpointsConfig.d.ts +56 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/resolveEndpoint.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/aws.d.ts +2 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/index.d.ts +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/lib/aws/index.d.ts +3 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/lib/aws/isVirtualHostableS3Bucket.d.ts +4 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/lib/aws/parseArn.d.ts +2 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/lib/aws/partition.d.ts +28 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/lib/isIpAddress.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/resolveDefaultAwsRegionalEndpointsConfig.d.ts +35 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/resolveEndpoint.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/types/EndpointError.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/types/EndpointRuleObject.d.ts +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/types/ErrorRuleObject.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/types/RuleSetObject.d.ts +5 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/types/TreeRuleObject.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/types/index.d.ts +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/ts3.4/types/shared.d.ts +12 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/types/EndpointError.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/types/EndpointRuleObject.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/types/ErrorRuleObject.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/types/RuleSetObject.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/types/TreeRuleObject.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/types/index.d.ts +6 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/dist-types/types/shared.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudformation/node_modules/@aws-sdk/util-endpoints/package.json +60 -0
- package/node_modules/@aws-sdk/client-cloudformation/package.json +2 -2
- package/package.json +2 -2
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { isValidHostLabel } from "@smithy/util-endpoints";
|
|
2
|
+
import { isIpAddress } from "../isIpAddress";
|
|
3
|
+
export const isVirtualHostableS3Bucket = (value, allowSubDomains = false) => {
|
|
4
|
+
if (allowSubDomains) {
|
|
5
|
+
for (const label of value.split(".")) {
|
|
6
|
+
if (!isVirtualHostableS3Bucket(label)) {
|
|
7
|
+
return false;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
return true;
|
|
11
|
+
}
|
|
12
|
+
if (!isValidHostLabel(value)) {
|
|
13
|
+
return false;
|
|
14
|
+
}
|
|
15
|
+
if (value.length < 3 || value.length > 63) {
|
|
16
|
+
return false;
|
|
17
|
+
}
|
|
18
|
+
if (value !== value.toLowerCase()) {
|
|
19
|
+
return false;
|
|
20
|
+
}
|
|
21
|
+
if (isIpAddress(value)) {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
return true;
|
|
25
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
const ARN_DELIMITER = ":";
|
|
2
|
+
const RESOURCE_DELIMITER = "/";
|
|
3
|
+
export const parseArn = (value) => {
|
|
4
|
+
const segments = value.split(ARN_DELIMITER);
|
|
5
|
+
if (segments.length < 6)
|
|
6
|
+
return null;
|
|
7
|
+
const [arn, partition, service, region, accountId, ...resourcePath] = segments;
|
|
8
|
+
if (arn !== "arn" || partition === "" || service === "" || resourcePath.join(ARN_DELIMITER) === "")
|
|
9
|
+
return null;
|
|
10
|
+
const resourceId = resourcePath.map((resource) => resource.split(RESOURCE_DELIMITER)).flat();
|
|
11
|
+
return {
|
|
12
|
+
partition,
|
|
13
|
+
service,
|
|
14
|
+
region,
|
|
15
|
+
accountId,
|
|
16
|
+
resourceId,
|
|
17
|
+
};
|
|
18
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import partitionsInfo from "./partitions.json";
|
|
2
|
+
let selectedPartitionsInfo = partitionsInfo;
|
|
3
|
+
let selectedUserAgentPrefix = "";
|
|
4
|
+
export const partition = (value) => {
|
|
5
|
+
const { partitions } = selectedPartitionsInfo;
|
|
6
|
+
for (const partition of partitions) {
|
|
7
|
+
const { regions, outputs } = partition;
|
|
8
|
+
for (const [region, regionData] of Object.entries(regions)) {
|
|
9
|
+
if (region === value) {
|
|
10
|
+
return {
|
|
11
|
+
...outputs,
|
|
12
|
+
...regionData,
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
for (const partition of partitions) {
|
|
18
|
+
const { regionRegex, outputs } = partition;
|
|
19
|
+
if (new RegExp(regionRegex).test(value)) {
|
|
20
|
+
return {
|
|
21
|
+
...outputs,
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
const DEFAULT_PARTITION = partitions.find((partition) => partition.id === "aws");
|
|
26
|
+
if (!DEFAULT_PARTITION) {
|
|
27
|
+
throw new Error("Provided region was not found in the partition array or regex," +
|
|
28
|
+
" and default partition with id 'aws' doesn't exist.");
|
|
29
|
+
}
|
|
30
|
+
return {
|
|
31
|
+
...DEFAULT_PARTITION.outputs,
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
export const setPartitionInfo = (partitionsInfo, userAgentPrefix = "") => {
|
|
35
|
+
selectedPartitionsInfo = partitionsInfo;
|
|
36
|
+
selectedUserAgentPrefix = userAgentPrefix;
|
|
37
|
+
};
|
|
38
|
+
export const useDefaultPartitionInfo = () => {
|
|
39
|
+
setPartitionInfo(partitionsInfo, "");
|
|
40
|
+
};
|
|
41
|
+
export const getUserAgentPrefix = () => selectedUserAgentPrefix;
|
|
@@ -0,0 +1,267 @@
|
|
|
1
|
+
{
|
|
2
|
+
"partitions": [{
|
|
3
|
+
"id": "aws",
|
|
4
|
+
"outputs": {
|
|
5
|
+
"dnsSuffix": "amazonaws.com",
|
|
6
|
+
"dualStackDnsSuffix": "api.aws",
|
|
7
|
+
"implicitGlobalRegion": "us-east-1",
|
|
8
|
+
"name": "aws",
|
|
9
|
+
"supportsDualStack": true,
|
|
10
|
+
"supportsFIPS": true
|
|
11
|
+
},
|
|
12
|
+
"regionRegex": "^(us|eu|ap|sa|ca|me|af|il|mx)\\-\\w+\\-\\d+$",
|
|
13
|
+
"regions": {
|
|
14
|
+
"af-south-1": {
|
|
15
|
+
"description": "Africa (Cape Town)"
|
|
16
|
+
},
|
|
17
|
+
"ap-east-1": {
|
|
18
|
+
"description": "Asia Pacific (Hong Kong)"
|
|
19
|
+
},
|
|
20
|
+
"ap-east-2": {
|
|
21
|
+
"description": "Asia Pacific (Taipei)"
|
|
22
|
+
},
|
|
23
|
+
"ap-northeast-1": {
|
|
24
|
+
"description": "Asia Pacific (Tokyo)"
|
|
25
|
+
},
|
|
26
|
+
"ap-northeast-2": {
|
|
27
|
+
"description": "Asia Pacific (Seoul)"
|
|
28
|
+
},
|
|
29
|
+
"ap-northeast-3": {
|
|
30
|
+
"description": "Asia Pacific (Osaka)"
|
|
31
|
+
},
|
|
32
|
+
"ap-south-1": {
|
|
33
|
+
"description": "Asia Pacific (Mumbai)"
|
|
34
|
+
},
|
|
35
|
+
"ap-south-2": {
|
|
36
|
+
"description": "Asia Pacific (Hyderabad)"
|
|
37
|
+
},
|
|
38
|
+
"ap-southeast-1": {
|
|
39
|
+
"description": "Asia Pacific (Singapore)"
|
|
40
|
+
},
|
|
41
|
+
"ap-southeast-2": {
|
|
42
|
+
"description": "Asia Pacific (Sydney)"
|
|
43
|
+
},
|
|
44
|
+
"ap-southeast-3": {
|
|
45
|
+
"description": "Asia Pacific (Jakarta)"
|
|
46
|
+
},
|
|
47
|
+
"ap-southeast-4": {
|
|
48
|
+
"description": "Asia Pacific (Melbourne)"
|
|
49
|
+
},
|
|
50
|
+
"ap-southeast-5": {
|
|
51
|
+
"description": "Asia Pacific (Malaysia)"
|
|
52
|
+
},
|
|
53
|
+
"ap-southeast-6": {
|
|
54
|
+
"description": "Asia Pacific (New Zealand)"
|
|
55
|
+
},
|
|
56
|
+
"ap-southeast-7": {
|
|
57
|
+
"description": "Asia Pacific (Thailand)"
|
|
58
|
+
},
|
|
59
|
+
"aws-global": {
|
|
60
|
+
"description": "aws global region"
|
|
61
|
+
},
|
|
62
|
+
"ca-central-1": {
|
|
63
|
+
"description": "Canada (Central)"
|
|
64
|
+
},
|
|
65
|
+
"ca-west-1": {
|
|
66
|
+
"description": "Canada West (Calgary)"
|
|
67
|
+
},
|
|
68
|
+
"eu-central-1": {
|
|
69
|
+
"description": "Europe (Frankfurt)"
|
|
70
|
+
},
|
|
71
|
+
"eu-central-2": {
|
|
72
|
+
"description": "Europe (Zurich)"
|
|
73
|
+
},
|
|
74
|
+
"eu-north-1": {
|
|
75
|
+
"description": "Europe (Stockholm)"
|
|
76
|
+
},
|
|
77
|
+
"eu-south-1": {
|
|
78
|
+
"description": "Europe (Milan)"
|
|
79
|
+
},
|
|
80
|
+
"eu-south-2": {
|
|
81
|
+
"description": "Europe (Spain)"
|
|
82
|
+
},
|
|
83
|
+
"eu-west-1": {
|
|
84
|
+
"description": "Europe (Ireland)"
|
|
85
|
+
},
|
|
86
|
+
"eu-west-2": {
|
|
87
|
+
"description": "Europe (London)"
|
|
88
|
+
},
|
|
89
|
+
"eu-west-3": {
|
|
90
|
+
"description": "Europe (Paris)"
|
|
91
|
+
},
|
|
92
|
+
"il-central-1": {
|
|
93
|
+
"description": "Israel (Tel Aviv)"
|
|
94
|
+
},
|
|
95
|
+
"me-central-1": {
|
|
96
|
+
"description": "Middle East (UAE)"
|
|
97
|
+
},
|
|
98
|
+
"me-south-1": {
|
|
99
|
+
"description": "Middle East (Bahrain)"
|
|
100
|
+
},
|
|
101
|
+
"mx-central-1": {
|
|
102
|
+
"description": "Mexico (Central)"
|
|
103
|
+
},
|
|
104
|
+
"sa-east-1": {
|
|
105
|
+
"description": "South America (Sao Paulo)"
|
|
106
|
+
},
|
|
107
|
+
"us-east-1": {
|
|
108
|
+
"description": "US East (N. Virginia)"
|
|
109
|
+
},
|
|
110
|
+
"us-east-2": {
|
|
111
|
+
"description": "US East (Ohio)"
|
|
112
|
+
},
|
|
113
|
+
"us-west-1": {
|
|
114
|
+
"description": "US West (N. California)"
|
|
115
|
+
},
|
|
116
|
+
"us-west-2": {
|
|
117
|
+
"description": "US West (Oregon)"
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}, {
|
|
121
|
+
"id": "aws-cn",
|
|
122
|
+
"outputs": {
|
|
123
|
+
"dnsSuffix": "amazonaws.com.cn",
|
|
124
|
+
"dualStackDnsSuffix": "api.amazonwebservices.com.cn",
|
|
125
|
+
"implicitGlobalRegion": "cn-northwest-1",
|
|
126
|
+
"name": "aws-cn",
|
|
127
|
+
"supportsDualStack": true,
|
|
128
|
+
"supportsFIPS": true
|
|
129
|
+
},
|
|
130
|
+
"regionRegex": "^cn\\-\\w+\\-\\d+$",
|
|
131
|
+
"regions": {
|
|
132
|
+
"aws-cn-global": {
|
|
133
|
+
"description": "aws-cn global region"
|
|
134
|
+
},
|
|
135
|
+
"cn-north-1": {
|
|
136
|
+
"description": "China (Beijing)"
|
|
137
|
+
},
|
|
138
|
+
"cn-northwest-1": {
|
|
139
|
+
"description": "China (Ningxia)"
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}, {
|
|
143
|
+
"id": "aws-eusc",
|
|
144
|
+
"outputs": {
|
|
145
|
+
"dnsSuffix": "amazonaws.eu",
|
|
146
|
+
"dualStackDnsSuffix": "api.amazonwebservices.eu",
|
|
147
|
+
"implicitGlobalRegion": "eusc-de-east-1",
|
|
148
|
+
"name": "aws-eusc",
|
|
149
|
+
"supportsDualStack": true,
|
|
150
|
+
"supportsFIPS": true
|
|
151
|
+
},
|
|
152
|
+
"regionRegex": "^eusc\\-(de)\\-\\w+\\-\\d+$",
|
|
153
|
+
"regions": {
|
|
154
|
+
"eusc-de-east-1": {
|
|
155
|
+
"description": "AWS European Sovereign Cloud (Germany)"
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}, {
|
|
159
|
+
"id": "aws-iso",
|
|
160
|
+
"outputs": {
|
|
161
|
+
"dnsSuffix": "c2s.ic.gov",
|
|
162
|
+
"dualStackDnsSuffix": "api.aws.ic.gov",
|
|
163
|
+
"implicitGlobalRegion": "us-iso-east-1",
|
|
164
|
+
"name": "aws-iso",
|
|
165
|
+
"supportsDualStack": true,
|
|
166
|
+
"supportsFIPS": true
|
|
167
|
+
},
|
|
168
|
+
"regionRegex": "^us\\-iso\\-\\w+\\-\\d+$",
|
|
169
|
+
"regions": {
|
|
170
|
+
"aws-iso-global": {
|
|
171
|
+
"description": "aws-iso global region"
|
|
172
|
+
},
|
|
173
|
+
"us-iso-east-1": {
|
|
174
|
+
"description": "US ISO East"
|
|
175
|
+
},
|
|
176
|
+
"us-iso-west-1": {
|
|
177
|
+
"description": "US ISO WEST"
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
}, {
|
|
181
|
+
"id": "aws-iso-b",
|
|
182
|
+
"outputs": {
|
|
183
|
+
"dnsSuffix": "sc2s.sgov.gov",
|
|
184
|
+
"dualStackDnsSuffix": "api.aws.scloud",
|
|
185
|
+
"implicitGlobalRegion": "us-isob-east-1",
|
|
186
|
+
"name": "aws-iso-b",
|
|
187
|
+
"supportsDualStack": true,
|
|
188
|
+
"supportsFIPS": true
|
|
189
|
+
},
|
|
190
|
+
"regionRegex": "^us\\-isob\\-\\w+\\-\\d+$",
|
|
191
|
+
"regions": {
|
|
192
|
+
"aws-iso-b-global": {
|
|
193
|
+
"description": "aws-iso-b global region"
|
|
194
|
+
},
|
|
195
|
+
"us-isob-east-1": {
|
|
196
|
+
"description": "US ISOB East (Ohio)"
|
|
197
|
+
},
|
|
198
|
+
"us-isob-west-1": {
|
|
199
|
+
"description": "US ISOB West"
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
}, {
|
|
203
|
+
"id": "aws-iso-e",
|
|
204
|
+
"outputs": {
|
|
205
|
+
"dnsSuffix": "cloud.adc-e.uk",
|
|
206
|
+
"dualStackDnsSuffix": "api.cloud-aws.adc-e.uk",
|
|
207
|
+
"implicitGlobalRegion": "eu-isoe-west-1",
|
|
208
|
+
"name": "aws-iso-e",
|
|
209
|
+
"supportsDualStack": true,
|
|
210
|
+
"supportsFIPS": true
|
|
211
|
+
},
|
|
212
|
+
"regionRegex": "^eu\\-isoe\\-\\w+\\-\\d+$",
|
|
213
|
+
"regions": {
|
|
214
|
+
"aws-iso-e-global": {
|
|
215
|
+
"description": "aws-iso-e global region"
|
|
216
|
+
},
|
|
217
|
+
"eu-isoe-west-1": {
|
|
218
|
+
"description": "EU ISOE West"
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
}, {
|
|
222
|
+
"id": "aws-iso-f",
|
|
223
|
+
"outputs": {
|
|
224
|
+
"dnsSuffix": "csp.hci.ic.gov",
|
|
225
|
+
"dualStackDnsSuffix": "api.aws.hci.ic.gov",
|
|
226
|
+
"implicitGlobalRegion": "us-isof-south-1",
|
|
227
|
+
"name": "aws-iso-f",
|
|
228
|
+
"supportsDualStack": true,
|
|
229
|
+
"supportsFIPS": true
|
|
230
|
+
},
|
|
231
|
+
"regionRegex": "^us\\-isof\\-\\w+\\-\\d+$",
|
|
232
|
+
"regions": {
|
|
233
|
+
"aws-iso-f-global": {
|
|
234
|
+
"description": "aws-iso-f global region"
|
|
235
|
+
},
|
|
236
|
+
"us-isof-east-1": {
|
|
237
|
+
"description": "US ISOF EAST"
|
|
238
|
+
},
|
|
239
|
+
"us-isof-south-1": {
|
|
240
|
+
"description": "US ISOF SOUTH"
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
}, {
|
|
244
|
+
"id": "aws-us-gov",
|
|
245
|
+
"outputs": {
|
|
246
|
+
"dnsSuffix": "amazonaws.com",
|
|
247
|
+
"dualStackDnsSuffix": "api.aws",
|
|
248
|
+
"implicitGlobalRegion": "us-gov-west-1",
|
|
249
|
+
"name": "aws-us-gov",
|
|
250
|
+
"supportsDualStack": true,
|
|
251
|
+
"supportsFIPS": true
|
|
252
|
+
},
|
|
253
|
+
"regionRegex": "^us\\-gov\\-\\w+\\-\\d+$",
|
|
254
|
+
"regions": {
|
|
255
|
+
"aws-us-gov-global": {
|
|
256
|
+
"description": "aws-us-gov global region"
|
|
257
|
+
},
|
|
258
|
+
"us-gov-east-1": {
|
|
259
|
+
"description": "AWS GovCloud (US-East)"
|
|
260
|
+
},
|
|
261
|
+
"us-gov-west-1": {
|
|
262
|
+
"description": "AWS GovCloud (US-West)"
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
}],
|
|
266
|
+
"version": "1.1"
|
|
267
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { isIpAddress } from "@smithy/util-endpoints";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { parseUrl } from "@smithy/url-parser";
|
|
2
|
+
export const resolveDefaultAwsRegionalEndpointsConfig = (input) => {
|
|
3
|
+
if (typeof input.endpointProvider !== "function") {
|
|
4
|
+
throw new Error("@aws-sdk/util-endpoint - endpointProvider and endpoint missing in config for this client.");
|
|
5
|
+
}
|
|
6
|
+
const { endpoint } = input;
|
|
7
|
+
if (endpoint === undefined) {
|
|
8
|
+
input.endpoint = async () => {
|
|
9
|
+
return toEndpointV1(input.endpointProvider({
|
|
10
|
+
Region: typeof input.region === "function" ? await input.region() : input.region,
|
|
11
|
+
UseDualStack: typeof input.useDualstackEndpoint === "function"
|
|
12
|
+
? await input.useDualstackEndpoint()
|
|
13
|
+
: input.useDualstackEndpoint,
|
|
14
|
+
UseFIPS: typeof input.useFipsEndpoint === "function" ? await input.useFipsEndpoint() : input.useFipsEndpoint,
|
|
15
|
+
Endpoint: undefined,
|
|
16
|
+
}, { logger: input.logger }));
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
return input;
|
|
20
|
+
};
|
|
21
|
+
export const toEndpointV1 = (endpoint) => parseUrl(endpoint.url);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { resolveEndpoint } from "@smithy/util-endpoints";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { EndpointError } from "@smithy/util-endpoints";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { EndpointARN } from "@smithy/types";
|
|
2
|
+
/**
|
|
3
|
+
* Evaluates a single string argument value, and returns an object containing
|
|
4
|
+
* details about the parsed ARN.
|
|
5
|
+
* If the input was not a valid ARN, the function returns null.
|
|
6
|
+
*/
|
|
7
|
+
export declare const parseArn: (value: string) => EndpointARN | null;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { EndpointPartition } from "@smithy/types";
|
|
2
|
+
export type PartitionsInfo = {
|
|
3
|
+
partitions: Array<{
|
|
4
|
+
id: string;
|
|
5
|
+
outputs: {
|
|
6
|
+
dnsSuffix: string;
|
|
7
|
+
dualStackDnsSuffix: string;
|
|
8
|
+
name: string;
|
|
9
|
+
supportsDualStack: boolean;
|
|
10
|
+
supportsFIPS: boolean;
|
|
11
|
+
};
|
|
12
|
+
regionRegex: string;
|
|
13
|
+
regions: Record<string, {
|
|
14
|
+
description?: string;
|
|
15
|
+
} | undefined>;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* Evaluates a single string argument value as a region, and matches the
|
|
20
|
+
* string value to an AWS partition.
|
|
21
|
+
* The matcher MUST always return a successful object describing the partition
|
|
22
|
+
* that the region has been determined to be a part of.
|
|
23
|
+
*/
|
|
24
|
+
export declare const partition: (value: string) => EndpointPartition;
|
|
25
|
+
/**
|
|
26
|
+
* Set custom partitions.json data.
|
|
27
|
+
* @internal
|
|
28
|
+
*/
|
|
29
|
+
export declare const setPartitionInfo: (partitionsInfo: PartitionsInfo, userAgentPrefix?: string) => void;
|
|
30
|
+
/**
|
|
31
|
+
* Reset to the default partitions.json data.
|
|
32
|
+
* @internal
|
|
33
|
+
*/
|
|
34
|
+
export declare const useDefaultPartitionInfo: () => void;
|
|
35
|
+
/**
|
|
36
|
+
* @internal
|
|
37
|
+
*/
|
|
38
|
+
export declare const getUserAgentPrefix: () => string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { isIpAddress } from "@smithy/util-endpoints";
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import type { Endpoint, EndpointParameters, EndpointV2, Logger, Provider } from "@smithy/types";
|
|
2
|
+
/**
|
|
3
|
+
* This is an additional config resolver layer for clients using the default
|
|
4
|
+
* AWS regional endpoints ruleset. It makes the *resolved* config guarantee the presence of an
|
|
5
|
+
* endpoint provider function. This differs from the base behavior of the Endpoint
|
|
6
|
+
* config resolver, which only normalizes config.endpoint IFF one is provided by the caller.
|
|
7
|
+
*
|
|
8
|
+
* This is not used by AWS SDK clients, but rather
|
|
9
|
+
* generated clients that have the aws.api#service trait. This includes protocol tests
|
|
10
|
+
* and other customers.
|
|
11
|
+
*
|
|
12
|
+
* This resolver is MUTUALLY EXCLUSIVE with the EndpointRequired config resolver from
|
|
13
|
+
* |@smithy/middleware-endpoint.
|
|
14
|
+
*
|
|
15
|
+
* It must be placed after the `resolveEndpointConfig`
|
|
16
|
+
* resolver. This replaces the endpoints.json-based default endpoint provider.
|
|
17
|
+
*
|
|
18
|
+
* @public
|
|
19
|
+
*/
|
|
20
|
+
export type DefaultAwsRegionalEndpointsInputConfig = {
|
|
21
|
+
endpoint?: unknown;
|
|
22
|
+
};
|
|
23
|
+
type PreviouslyResolved = {
|
|
24
|
+
logger?: Logger;
|
|
25
|
+
region?: undefined | string | Provider<string | undefined>;
|
|
26
|
+
useFipsEndpoint?: undefined | boolean | Provider<string | boolean>;
|
|
27
|
+
useDualstackEndpoint?: undefined | boolean | Provider<string | boolean>;
|
|
28
|
+
endpointProvider: (endpointParams: EndpointParameters | DefaultRegionalEndpointParameters, context?: {
|
|
29
|
+
logger?: Logger;
|
|
30
|
+
}) => EndpointV2;
|
|
31
|
+
};
|
|
32
|
+
/**
|
|
33
|
+
* @internal
|
|
34
|
+
*/
|
|
35
|
+
type DefaultRegionalEndpointParameters = {
|
|
36
|
+
Region?: string | undefined;
|
|
37
|
+
UseDualStack?: boolean | undefined;
|
|
38
|
+
UseFIPS?: boolean | undefined;
|
|
39
|
+
};
|
|
40
|
+
/**
|
|
41
|
+
* @internal
|
|
42
|
+
*/
|
|
43
|
+
export interface DefaultAwsRegionalEndpointsResolvedConfig {
|
|
44
|
+
endpoint: Provider<Endpoint>;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* MUST resolve after `\@smithy/middleware-endpoint`::`resolveEndpointConfig`.
|
|
48
|
+
*
|
|
49
|
+
* @internal
|
|
50
|
+
*/
|
|
51
|
+
export declare const resolveDefaultAwsRegionalEndpointsConfig: <T>(input: T & DefaultAwsRegionalEndpointsInputConfig & PreviouslyResolved) => T & DefaultAwsRegionalEndpointsResolvedConfig;
|
|
52
|
+
/**
|
|
53
|
+
* @internal
|
|
54
|
+
*/
|
|
55
|
+
export declare const toEndpointV1: (endpoint: EndpointV2) => Endpoint;
|
|
56
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { resolveEndpoint } from "@smithy/util-endpoints";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { EndpointPartition } from "@smithy/types";
|
|
2
|
+
export type PartitionsInfo = {
|
|
3
|
+
partitions: Array<{
|
|
4
|
+
id: string;
|
|
5
|
+
outputs: {
|
|
6
|
+
dnsSuffix: string;
|
|
7
|
+
dualStackDnsSuffix: string;
|
|
8
|
+
name: string;
|
|
9
|
+
supportsDualStack: boolean;
|
|
10
|
+
supportsFIPS: boolean;
|
|
11
|
+
};
|
|
12
|
+
regionRegex: string;
|
|
13
|
+
regions: Record<
|
|
14
|
+
string,
|
|
15
|
+
| {
|
|
16
|
+
description?: string;
|
|
17
|
+
}
|
|
18
|
+
| undefined
|
|
19
|
+
>;
|
|
20
|
+
}>;
|
|
21
|
+
};
|
|
22
|
+
export declare const partition: (value: string) => EndpointPartition;
|
|
23
|
+
export declare const setPartitionInfo: (
|
|
24
|
+
partitionsInfo: PartitionsInfo,
|
|
25
|
+
userAgentPrefix?: string
|
|
26
|
+
) => void;
|
|
27
|
+
export declare const useDefaultPartitionInfo: () => void;
|
|
28
|
+
export declare const getUserAgentPrefix: () => string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { isIpAddress } from "@smithy/util-endpoints";
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Endpoint,
|
|
3
|
+
EndpointParameters,
|
|
4
|
+
EndpointV2,
|
|
5
|
+
Logger,
|
|
6
|
+
Provider,
|
|
7
|
+
} from "@smithy/types";
|
|
8
|
+
export type DefaultAwsRegionalEndpointsInputConfig = {
|
|
9
|
+
endpoint?: unknown;
|
|
10
|
+
};
|
|
11
|
+
type PreviouslyResolved = {
|
|
12
|
+
logger?: Logger;
|
|
13
|
+
region?: undefined | string | Provider<string | undefined>;
|
|
14
|
+
useFipsEndpoint?: undefined | boolean | Provider<string | boolean>;
|
|
15
|
+
useDualstackEndpoint?: undefined | boolean | Provider<string | boolean>;
|
|
16
|
+
endpointProvider: (
|
|
17
|
+
endpointParams: EndpointParameters | DefaultRegionalEndpointParameters,
|
|
18
|
+
context?: {
|
|
19
|
+
logger?: Logger;
|
|
20
|
+
}
|
|
21
|
+
) => EndpointV2;
|
|
22
|
+
};
|
|
23
|
+
type DefaultRegionalEndpointParameters = {
|
|
24
|
+
Region?: string | undefined;
|
|
25
|
+
UseDualStack?: boolean | undefined;
|
|
26
|
+
UseFIPS?: boolean | undefined;
|
|
27
|
+
};
|
|
28
|
+
export interface DefaultAwsRegionalEndpointsResolvedConfig {
|
|
29
|
+
endpoint: Provider<Endpoint>;
|
|
30
|
+
}
|
|
31
|
+
export declare const resolveDefaultAwsRegionalEndpointsConfig: <T>(
|
|
32
|
+
input: T & DefaultAwsRegionalEndpointsInputConfig & PreviouslyResolved
|
|
33
|
+
) => T & DefaultAwsRegionalEndpointsResolvedConfig;
|
|
34
|
+
export declare const toEndpointV1: (endpoint: EndpointV2) => Endpoint;
|
|
35
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { resolveEndpoint } from "@smithy/util-endpoints";
|