@axway/axway-central-cli 3.4.0 → 3.5.0-rc.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.
|
@@ -49,6 +49,7 @@ const agentInstallFlows = {
|
|
|
49
49
|
[_types.GatewayTypes.AWS_GATEWAY]: awsAgents.AWSInstallMethods,
|
|
50
50
|
[_types.GatewayTypes.GITLAB]: gitLabAgents.GitLabInstallMethods,
|
|
51
51
|
[_types.GatewayTypes.AZURE_GATEWAY]: azureAgents.AzureInstallMethods,
|
|
52
|
+
[_types.GatewayTypes.AZURE_EVENTHUB]: azureAgents.AzureInstallMethods,
|
|
52
53
|
[_types.GatewayTypes.ISTIO]: istioAgents.IstioInstallMethods,
|
|
53
54
|
[_types.GatewayTypes.KAFKA]: kafkaAgents.KafkaInstallMethods,
|
|
54
55
|
[_types.GatewayTypes.GRAYLOG]: graylogAgent.GraylogInstallMethods,
|
|
@@ -61,7 +62,8 @@ const saasAgentInstallFlows = {
|
|
|
61
62
|
[_types.SaaSGatewayTypes.GITHUB]: gitHubAgents.GitHubSaaSInstallMethods,
|
|
62
63
|
[_types.SaaSGatewayTypes.APIGEEX_GATEWAY]: apigeeSaaSAgents.APIGEEXSaaSInstallMethods,
|
|
63
64
|
[_types.SaaSGatewayTypes.SWAGGERHUB]: swaggerHubAgents.SwaggerHubSaaSInstallMethods,
|
|
64
|
-
[_types.GatewayTypes.AZURE_GATEWAY]: azureSaasAgents.AzureSaaSInstallMethods
|
|
65
|
+
[_types.GatewayTypes.AZURE_GATEWAY]: azureSaasAgents.AzureSaaSInstallMethods,
|
|
66
|
+
[_types.GatewayTypes.AZURE_EVENTHUB]: azureSaasAgents.AzureSaaSInstallMethods
|
|
65
67
|
};
|
|
66
68
|
const createConfigBackup = async (configFiles, gatewayType) => {
|
|
67
69
|
// If current configurations exist, back them up
|
|
@@ -138,7 +140,7 @@ const agents = exports.agents = {
|
|
|
138
140
|
});
|
|
139
141
|
|
|
140
142
|
// if this check gets bigger, may think about an array of agents that can be both ground and embedded until ground agents become obsolete
|
|
141
|
-
if (gatewayType === _types.GatewayTypes.AWS_GATEWAY || gatewayType
|
|
143
|
+
if (gatewayType === _types.GatewayTypes.AWS_GATEWAY || gatewayType === _types.GatewayTypes.AZURE_GATEWAY || gatewayType === _types.GatewayTypes.AZURE_EVENTHUB) {
|
|
142
144
|
// hosted vs on premise
|
|
143
145
|
installConfig.switches.isHostedInstall = (await (0, _basicPrompts.askList)({
|
|
144
146
|
msg: prompts.hostedAgentOption,
|
|
@@ -163,7 +165,7 @@ const agents = exports.agents = {
|
|
|
163
165
|
}
|
|
164
166
|
|
|
165
167
|
// Create the object of GatewayTypes -> BundleType functions
|
|
166
|
-
installConfig.bundleType = await agentInstallFlow.GetBundleType();
|
|
168
|
+
installConfig.bundleType = await agentInstallFlow.GetBundleType(installConfig.gatewayType);
|
|
167
169
|
installConfig.switches.isDaEnabled = installConfig.bundleType === _types.BundleType.ALL_AGENTS || installConfig.bundleType === _types.BundleType.DISCOVERY;
|
|
168
170
|
installConfig.switches.isTaEnabled = installConfig.bundleType === _types.BundleType.ALL_AGENTS || installConfig.bundleType === _types.BundleType.TRACEABILITY || installConfig.bundleType === _types.BundleType.TRACEABILITY_OFFLINE;
|
|
169
171
|
|
|
@@ -49,11 +49,16 @@ const AzurePrompts = {
|
|
|
49
49
|
enterResourceGroupName: 'Enter the Azure Resource Group Name',
|
|
50
50
|
enterApiManagementServiceName: 'Enter the Azure API Management Service Name'
|
|
51
51
|
};
|
|
52
|
-
const askBundleType = async
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
52
|
+
const askBundleType = async gateway => {
|
|
53
|
+
console.log(gateway);
|
|
54
|
+
if (gateway === _types.GatewayTypes.AZURE_GATEWAY) {
|
|
55
|
+
return await (0, _basicPrompts.askList)({
|
|
56
|
+
msg: helpers.agentMessages.selectAgentType,
|
|
57
|
+
choices: [_types.BundleType.ALL_AGENTS, _types.BundleType.DISCOVERY, _types.BundleType.TRACEABILITY]
|
|
58
|
+
});
|
|
59
|
+
} else {
|
|
60
|
+
return _types.BundleType.DISCOVERY;
|
|
61
|
+
}
|
|
57
62
|
};
|
|
58
63
|
exports.askBundleType = askBundleType;
|
|
59
64
|
const askConfigType = async () => {
|
|
@@ -98,13 +103,19 @@ const askAzurePolicyKey = async () => await (0, _basicPrompts.askInput)({
|
|
|
98
103
|
});
|
|
99
104
|
const gatewayConnectivity = async installConfig => {
|
|
100
105
|
const azureAgentValues = new _azureTemplates.AzureAgentValues();
|
|
101
|
-
|
|
102
|
-
|
|
106
|
+
if (installConfig.gatewayType === _types.GatewayTypes.AZURE_EVENTHUB) {
|
|
107
|
+
azureAgentValues.isAzureEventHub = true;
|
|
108
|
+
console.log('\nCONNECTION TO AZURE EVENTHUB:');
|
|
109
|
+
console.log(_chalk.default.gray(`The discovery agent needs to connect to the Azure EventHub to discover API's for publishing to Amplify.\n`));
|
|
110
|
+
} else {
|
|
111
|
+
console.log('\nCONNECTION TO AZURE:');
|
|
112
|
+
console.log(_chalk.default.gray(`The discovery agent needs to connect to the Azure API Gateway to discover API's for publishing to Amplify.\nThe traceability agent needs to connect to an Azure Event Hub for collecting APIs transactions. These will be forwarded to the Business Insights.\n`));
|
|
113
|
+
}
|
|
103
114
|
|
|
104
115
|
// Azure Discovery Agent Prompts
|
|
105
116
|
if (installConfig.switches.isDaEnabled) {
|
|
106
117
|
console.log(_chalk.default.gray(`\nDiscovery Agent Configuration\nThe discovery agent needs to connect to Azure using a service principal with password based authentication. Refer to https://docs.microsoft.com/en-us/cli/azure/create-an-azure-service-principal-azure-cli for creating such service principal using Azure CLI.`));
|
|
107
|
-
await askDiscoveryPrompts(azureAgentValues);
|
|
118
|
+
await askDiscoveryPrompts(azureAgentValues, installConfig.gatewayType);
|
|
108
119
|
}
|
|
109
120
|
|
|
110
121
|
// Azure Traceability Agent Prompts
|
|
@@ -113,7 +124,7 @@ const gatewayConnectivity = async installConfig => {
|
|
|
113
124
|
await askTraceabilityPrompts(azureAgentValues);
|
|
114
125
|
// ask discovery prompts without asking for an agent name, or displaying the Discovery Configuration message
|
|
115
126
|
if (installConfig.switches.isTaEnabled && !installConfig.switches.isDaEnabled) {
|
|
116
|
-
await askDiscoveryPrompts(azureAgentValues);
|
|
127
|
+
await askDiscoveryPrompts(azureAgentValues, installConfig.gatewayType);
|
|
117
128
|
}
|
|
118
129
|
}
|
|
119
130
|
return azureAgentValues;
|
|
@@ -163,7 +174,7 @@ const dockerSuccessMsg = installConfig => {
|
|
|
163
174
|
};
|
|
164
175
|
|
|
165
176
|
// Azure DA prompts
|
|
166
|
-
async function askDiscoveryPrompts(azureAgentValues) {
|
|
177
|
+
async function askDiscoveryPrompts(azureAgentValues, gatewayType) {
|
|
167
178
|
// Azure Tenant Id
|
|
168
179
|
azureAgentValues.tenantId = await askAzureTenantId();
|
|
169
180
|
// Azure Subscription Id
|
|
@@ -174,8 +185,14 @@ async function askDiscoveryPrompts(azureAgentValues) {
|
|
|
174
185
|
azureAgentValues.servicePrincipalClientSecret = await askAzureServicePrincipalClientSecret();
|
|
175
186
|
// Azure Resource Group Name
|
|
176
187
|
azureAgentValues.resourceGroupName = await askAzureResourceGroupName();
|
|
177
|
-
|
|
178
|
-
|
|
188
|
+
if (gatewayType === _types.GatewayTypes.AZURE_GATEWAY) {
|
|
189
|
+
// Azure API Management Service Name
|
|
190
|
+
azureAgentValues.apiManagementServiceName = await askAzureapiManagementServiceName();
|
|
191
|
+
}
|
|
192
|
+
if (gatewayType === _types.GatewayTypes.AZURE_EVENTHUB) {
|
|
193
|
+
// Azure Event Hub Namespace
|
|
194
|
+
azureAgentValues.eventHubNamespace = await askAzureEventHubNamespace();
|
|
195
|
+
}
|
|
179
196
|
}
|
|
180
197
|
async function askTraceabilityPrompts(azureAgentValues) {
|
|
181
198
|
// Azure Event Hub Namespace
|
|
@@ -31,12 +31,13 @@ class DataplaneConfig {
|
|
|
31
31
|
}
|
|
32
32
|
}
|
|
33
33
|
class AzureDataplaneConfig extends DataplaneConfig {
|
|
34
|
-
constructor(tenantId, resourceGroup, subscriptionId, apimServiceName, eventHubName, eventHubNamespace, eventHubConsumerGroup) {
|
|
34
|
+
constructor(tenantId, resourceGroup, subscriptionId, apimServiceName, mode, eventHubName, eventHubNamespace, eventHubConsumerGroup) {
|
|
35
35
|
super('Azure');
|
|
36
36
|
_defineProperty(this, "tenantId", void 0);
|
|
37
37
|
_defineProperty(this, "resourceGroup", void 0);
|
|
38
38
|
_defineProperty(this, "subscriptionId", void 0);
|
|
39
39
|
_defineProperty(this, "apimServiceName", void 0);
|
|
40
|
+
_defineProperty(this, "mode", void 0);
|
|
40
41
|
_defineProperty(this, "eventHubName", void 0);
|
|
41
42
|
_defineProperty(this, "eventHubNamespace", void 0);
|
|
42
43
|
_defineProperty(this, "eventHubConsumerGroup", void 0);
|
|
@@ -44,6 +45,7 @@ class AzureDataplaneConfig extends DataplaneConfig {
|
|
|
44
45
|
this.resourceGroup = resourceGroup;
|
|
45
46
|
this.subscriptionId = subscriptionId;
|
|
46
47
|
this.apimServiceName = apimServiceName;
|
|
48
|
+
this.mode = mode;
|
|
47
49
|
this.eventHubName = eventHubName;
|
|
48
50
|
this.eventHubNamespace = eventHubNamespace;
|
|
49
51
|
this.eventHubConsumerGroup = eventHubConsumerGroup;
|
|
@@ -122,6 +124,7 @@ class SaasAzureAgentValues extends SaasAgentValues {
|
|
|
122
124
|
_defineProperty(this, "apimManagementServiceName", void 0);
|
|
123
125
|
_defineProperty(this, "subscriptionId", void 0);
|
|
124
126
|
_defineProperty(this, "tenantId", void 0);
|
|
127
|
+
_defineProperty(this, "mode", void 0);
|
|
125
128
|
this.clientID = '';
|
|
126
129
|
this.clientSecret = '';
|
|
127
130
|
this.sharedAccessKeyName = '';
|
|
@@ -133,6 +136,7 @@ class SaasAzureAgentValues extends SaasAgentValues {
|
|
|
133
136
|
this.apimManagementServiceName = '';
|
|
134
137
|
this.subscriptionId = '';
|
|
135
138
|
this.tenantId = '';
|
|
139
|
+
this.mode = _types.AzureDataplaneMode.APIM;
|
|
136
140
|
}
|
|
137
141
|
getAccessData() {
|
|
138
142
|
let data = JSON.stringify({
|
|
@@ -175,11 +179,15 @@ const SaasPrompts = {
|
|
|
175
179
|
MASKING_CHARS: 'Enter the characters to use when sanitizing a value',
|
|
176
180
|
ENTER_MORE: 'Do you want to enter another {0} for {1}'
|
|
177
181
|
};
|
|
178
|
-
const askBundleType = async
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
182
|
+
const askBundleType = async gateway => {
|
|
183
|
+
if (gateway === _types.GatewayTypes.AZURE_GATEWAY) {
|
|
184
|
+
return await (0, _basicPrompts.askList)({
|
|
185
|
+
msg: helpers.agentMessages.selectAgentType,
|
|
186
|
+
choices: [_types.BundleType.ALL_AGENTS, _types.BundleType.DISCOVERY]
|
|
187
|
+
});
|
|
188
|
+
} else {
|
|
189
|
+
return _types.BundleType.DISCOVERY;
|
|
190
|
+
}
|
|
183
191
|
};
|
|
184
192
|
exports.askBundleType = askBundleType;
|
|
185
193
|
const askConfigType = async () => {
|
|
@@ -300,10 +308,12 @@ const askForAzureCredentials = async (hostedAgentValues, installConfig) => {
|
|
|
300
308
|
hostedAgentValues.resourceGroup = await (0, _basicPrompts.askInput)({
|
|
301
309
|
msg: SaasPrompts.RESOURCE_GROUP_NAME
|
|
302
310
|
});
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
311
|
+
if (installConfig.gatewayType === _types.GatewayTypes.AZURE_GATEWAY) {
|
|
312
|
+
hostedAgentValues.apimManagementServiceName = await (0, _basicPrompts.askInput)({
|
|
313
|
+
msg: SaasPrompts.APIM_SERVICE_MANAGEMENT_NAME,
|
|
314
|
+
validate: (0, _basicPrompts.validateRegex)(helpers.AzureRegexPatterns.azureApiManagementServiceNameRegex, InvalidMessages.enterApiManagementServiceName)
|
|
315
|
+
});
|
|
316
|
+
}
|
|
307
317
|
if (installConfig.switches.isTaEnabled) {
|
|
308
318
|
hostedAgentValues.sharedAccessKeyName = await (0, _basicPrompts.askInput)({
|
|
309
319
|
msg: SaasPrompts.SHARED_ACCESS_KEY_NAME,
|
|
@@ -323,10 +333,15 @@ const gatewayConnectivity = async installConfig => {
|
|
|
323
333
|
|
|
324
334
|
// DeploymentType
|
|
325
335
|
let hostedAgentValues = new SaasAgentValues();
|
|
326
|
-
if (installConfig.gatewayType === _types.GatewayTypes.AZURE_GATEWAY) {
|
|
336
|
+
if (installConfig.gatewayType === _types.GatewayTypes.AZURE_GATEWAY || installConfig.gatewayType === _types.GatewayTypes.AZURE_EVENTHUB) {
|
|
327
337
|
// Azure connection details
|
|
328
338
|
hostedAgentValues = new SaasAzureAgentValues();
|
|
329
339
|
hostedAgentValues = await askForAzureCredentials(hostedAgentValues, installConfig);
|
|
340
|
+
if (installConfig.gatewayType === _types.GatewayTypes.AZURE_EVENTHUB) {
|
|
341
|
+
hostedAgentValues.eventHubNamespace = await (0, _basicPrompts.askInput)({
|
|
342
|
+
msg: SaasPrompts.EVENT_HUB_NAMESPACE
|
|
343
|
+
});
|
|
344
|
+
}
|
|
330
345
|
if (installConfig.switches.isTaEnabled) {
|
|
331
346
|
hostedAgentValues.eventHubName = await (0, _basicPrompts.askInput)({
|
|
332
347
|
msg: SaasPrompts.EVENT_HUB_NAME
|
|
@@ -446,11 +461,14 @@ const completeInstall = async (installConfig, apiServerClient, defsManager) => {
|
|
|
446
461
|
resourceFuncsForCleanup.push(cleanupFunc);
|
|
447
462
|
}
|
|
448
463
|
if (installConfig.gatewayType === _types.GatewayTypes.AZURE_GATEWAY) {
|
|
449
|
-
azureAgentValues.dataplaneConfig = new AzureDataplaneConfig(azureAgentValues.tenantId, azureAgentValues.resourceGroup, azureAgentValues.subscriptionId, azureAgentValues.apimManagementServiceName);
|
|
464
|
+
azureAgentValues.dataplaneConfig = new AzureDataplaneConfig(azureAgentValues.tenantId, azureAgentValues.resourceGroup, azureAgentValues.subscriptionId, azureAgentValues.apimManagementServiceName, _types.AzureDataplaneMode.APIM);
|
|
450
465
|
if (installConfig.switches.isTaEnabled) {
|
|
451
|
-
azureAgentValues.dataplaneConfig = new AzureDataplaneConfig(azureAgentValues.tenantId, azureAgentValues.resourceGroup, azureAgentValues.subscriptionId, azureAgentValues.apimManagementServiceName, azureAgentValues.eventHubName, azureAgentValues.eventHubNamespace, azureAgentValues.eventHubConsumerGroup);
|
|
466
|
+
azureAgentValues.dataplaneConfig = new AzureDataplaneConfig(azureAgentValues.tenantId, azureAgentValues.resourceGroup, azureAgentValues.subscriptionId, azureAgentValues.apimManagementServiceName, _types.AzureDataplaneMode.APIM, azureAgentValues.eventHubName, azureAgentValues.eventHubNamespace, azureAgentValues.eventHubConsumerGroup);
|
|
452
467
|
}
|
|
453
468
|
}
|
|
469
|
+
if (installConfig.gatewayType === _types.GatewayTypes.AZURE_EVENTHUB) {
|
|
470
|
+
azureAgentValues.dataplaneConfig = new AzureDataplaneConfig(azureAgentValues.tenantId, azureAgentValues.resourceGroup, azureAgentValues.subscriptionId, '', _types.AzureDataplaneMode.EventHub, undefined, azureAgentValues.eventHubNamespace);
|
|
471
|
+
}
|
|
454
472
|
// create the data plane resource
|
|
455
473
|
let dataplaneRes;
|
|
456
474
|
try {
|
|
@@ -23,6 +23,7 @@ class AzureAgentValues {
|
|
|
23
23
|
_defineProperty(this, "servicePrincipalClientSecret", void 0);
|
|
24
24
|
_defineProperty(this, "subscriptionId", void 0);
|
|
25
25
|
_defineProperty(this, "tenantId", void 0);
|
|
26
|
+
_defineProperty(this, "isAzureEventHub", void 0);
|
|
26
27
|
_defineProperty(this, "centralConfig", void 0);
|
|
27
28
|
_defineProperty(this, "traceabilityConfig", void 0);
|
|
28
29
|
this.apiManagementServiceName = '';
|
|
@@ -35,6 +36,7 @@ class AzureAgentValues {
|
|
|
35
36
|
this.servicePrincipalClientSecret = '';
|
|
36
37
|
this.subscriptionId = '';
|
|
37
38
|
this.tenantId = '';
|
|
39
|
+
this.isAzureEventHub = false;
|
|
38
40
|
this.centralConfig = new _types.CentralAgentConfig();
|
|
39
41
|
this.traceabilityConfig = new _types.TraceabilityConfig();
|
|
40
42
|
}
|
|
@@ -99,7 +101,11 @@ AZURE_SUBSCRIPTIONID={{subscriptionId}}
|
|
|
99
101
|
AZURE_RESOURCEGROUPNAME={{resourceGroupName}}
|
|
100
102
|
AZURE_CLIENTID={{servicePrincipalClientId}}
|
|
101
103
|
AZURE_CLIENTSECRET={{servicePrincipalClientSecret}}
|
|
104
|
+
{{#if isAzureEventHub}}
|
|
105
|
+
AZURE_EVENTHUBNAMESPACE={{eventHubNamespace}}
|
|
106
|
+
{{else}}
|
|
102
107
|
AZURE_APIMSERVICENAME={{apiManagementServiceName}}
|
|
108
|
+
{{/if}}
|
|
103
109
|
|
|
104
110
|
# Amplify Central configs
|
|
105
111
|
CENTRAL_AGENTNAME={{centralConfig.daAgentName}}
|
package/dist/common/types.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.docsUrl = exports.commonCmdArgsDescription = exports.cliVersionHeader = exports.YesNoChoices = exports.YesNo = exports.WAIT_TIMEOUT = exports.TrueFalseChoices = exports.TrueFalse = exports.TraceableRegionType = exports.TraceabilityConfig = exports.SingleEntryPointUrls = exports.SaaSGatewayTypes = exports.Regions = exports.PublicRepoUrl = exports.PublicDockerRepoBaseUrl = exports.Protocol = exports.ProdBaseUrls = exports.Platforms = exports.OutputTypes = exports.MAX_TABLE_STRING_LENGTH = exports.MAX_FILE_SIZE = exports.MAX_CACHE_FILE_SIZE = exports.LoggingSource = exports.LanguageTypes = exports.KindTypes = exports.Kind = exports.IstioProfileChoices = exports.IstioInstallValues = exports.IstioAgentValues = exports.IngestionProtocolToHosts = exports.IngestionProtocol = exports.IngestionHostsHTTP = exports.IngestionHosts = exports.IngestionHTTPHosts = exports.IDPType = exports.IDPConfiguration = exports.IDPClientSecretAuthMethod = exports.IDPAuthType = exports.IDPAuthConfiguration = exports.IDPAuthClientSecret = exports.IDPAuthAccessToken = exports.GatewayTypes = exports.GatewayTypeToDataPlane = exports.GatewayMode = exports.EnvironmentConfigInfo = exports.DosaAccount = exports.DataPlaneNames = exports.DOSAConfigInfo = exports.ConfigTypes = exports.CloudFormationConfig = exports.Certificate = exports.CentralAgentConfig = exports.CACHE_FILE_TTL_MILLISECONDS = exports.BundleType = exports.BasePaths = exports.AuthUrls = exports.AgentTypes = exports.AgentResourceKind = exports.AgentNames = exports.AgentInstallSwitches = exports.AgentInstallConfig = exports.AgentConfigTypes = exports.AWSRegions = exports.APIGEEXDISCOVERYMODES = exports.APICDeployments = exports.ABORT_TIMEOUT = void 0;
|
|
6
|
+
exports.docsUrl = exports.commonCmdArgsDescription = exports.cliVersionHeader = exports.YesNoChoices = exports.YesNo = exports.WAIT_TIMEOUT = exports.TrueFalseChoices = exports.TrueFalse = exports.TraceableRegionType = exports.TraceabilityConfig = exports.SingleEntryPointUrls = exports.SaaSGatewayTypes = exports.Regions = exports.PublicRepoUrl = exports.PublicDockerRepoBaseUrl = exports.Protocol = exports.ProdBaseUrls = exports.Platforms = exports.OutputTypes = exports.MAX_TABLE_STRING_LENGTH = exports.MAX_FILE_SIZE = exports.MAX_CACHE_FILE_SIZE = exports.LoggingSource = exports.LanguageTypes = exports.KindTypes = exports.Kind = exports.IstioProfileChoices = exports.IstioInstallValues = exports.IstioAgentValues = exports.IngestionProtocolToHosts = exports.IngestionProtocol = exports.IngestionHostsHTTP = exports.IngestionHosts = exports.IngestionHTTPHosts = exports.IDPType = exports.IDPConfiguration = exports.IDPClientSecretAuthMethod = exports.IDPAuthType = exports.IDPAuthConfiguration = exports.IDPAuthClientSecret = exports.IDPAuthAccessToken = exports.GatewayTypes = exports.GatewayTypeToDataPlane = exports.GatewayMode = exports.EnvironmentConfigInfo = exports.DosaAccount = exports.DataPlaneNames = exports.DOSAConfigInfo = exports.ConfigTypes = exports.CloudFormationConfig = exports.Certificate = exports.CentralAgentConfig = exports.CACHE_FILE_TTL_MILLISECONDS = exports.BundleType = exports.BasePaths = exports.AzureDataplaneMode = exports.AuthUrls = exports.AgentTypes = exports.AgentResourceKind = exports.AgentNames = exports.AgentInstallSwitches = exports.AgentInstallConfig = exports.AgentConfigTypes = exports.AWSRegions = exports.APIGEEXDISCOVERYMODES = exports.APICDeployments = exports.ABORT_TIMEOUT = void 0;
|
|
7
7
|
var _dataService = require("./dataService");
|
|
8
8
|
var _utils = require("./utils");
|
|
9
9
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
@@ -227,6 +227,7 @@ let AgentNames = exports.AgentNames = /*#__PURE__*/function (AgentNames) {
|
|
|
227
227
|
AgentNames["APIGEEX_TA"] = "apigee-traceability-agent";
|
|
228
228
|
AgentNames["AZURE_DA"] = "azure-discovery-agent";
|
|
229
229
|
AgentNames["AZURE_TA"] = "azure-traceability-agent";
|
|
230
|
+
AgentNames["AZURE_EVENTHUB_DA"] = "azure-eventhub-discovery-agent";
|
|
230
231
|
AgentNames["EDGE_DA"] = "v7-discovery-agent";
|
|
231
232
|
AgentNames["EDGE_TA"] = "v7-traceability-agent";
|
|
232
233
|
AgentNames["KAFKA_DA"] = "kafka-discovery-agent";
|
|
@@ -244,6 +245,7 @@ let GatewayTypes = exports.GatewayTypes = /*#__PURE__*/function (GatewayTypes) {
|
|
|
244
245
|
GatewayTypes["EDGE_GATEWAY"] = "Amplify API Gateway";
|
|
245
246
|
GatewayTypes["AWS_GATEWAY"] = "Amazon API Gateway";
|
|
246
247
|
GatewayTypes["AZURE_GATEWAY"] = "Azure API Gateway";
|
|
248
|
+
GatewayTypes["AZURE_EVENTHUB"] = "Azure EventHub";
|
|
247
249
|
GatewayTypes["GITLAB"] = "GitLab";
|
|
248
250
|
GatewayTypes["ISTIO"] = "Istio";
|
|
249
251
|
GatewayTypes["EDGE_GATEWAY_ONLY"] = "Amplify API Gateway only";
|
|
@@ -287,6 +289,7 @@ const GatewayTypeToDataPlane = exports.GatewayTypeToDataPlane = {
|
|
|
287
289
|
[SaaSGatewayTypes.GITHUB]: DataPlaneNames.GITHUB,
|
|
288
290
|
[GatewayTypes.GITLAB]: DataPlaneNames.GITLAB,
|
|
289
291
|
[GatewayTypes.AZURE_GATEWAY]: DataPlaneNames.AZURE,
|
|
292
|
+
[GatewayTypes.AZURE_EVENTHUB]: DataPlaneNames.AZURE,
|
|
290
293
|
[GatewayTypes.ISTIO]: 'Istio',
|
|
291
294
|
[SaaSGatewayTypes.APIGEEX_GATEWAY]: DataPlaneNames.APIGEE,
|
|
292
295
|
[GatewayTypes.KAFKA]: DataPlaneNames.KAFKA,
|
|
@@ -321,6 +324,11 @@ let APIGEEXDISCOVERYMODES = exports.APIGEEXDISCOVERYMODES = /*#__PURE__*/functio
|
|
|
321
324
|
APIGEEXDISCOVERYMODES["PRODUCT"] = "product";
|
|
322
325
|
return APIGEEXDISCOVERYMODES;
|
|
323
326
|
}({});
|
|
327
|
+
let AzureDataplaneMode = exports.AzureDataplaneMode = /*#__PURE__*/function (AzureDataplaneMode) {
|
|
328
|
+
AzureDataplaneMode["APIM"] = "APIM";
|
|
329
|
+
AzureDataplaneMode["EventHub"] = "EventHub";
|
|
330
|
+
return AzureDataplaneMode;
|
|
331
|
+
}({});
|
|
324
332
|
class EnvironmentConfigInfo {
|
|
325
333
|
constructor() {
|
|
326
334
|
_defineProperty(this, "name", void 0);
|