@axway/axway-central-cli 2.10.2 → 2.10.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/install/agents.js +2 -1
- package/dist/commands/install/helpers/templates/awsTemplates.js +2 -0
- package/dist/commands/install/helpers/templates/azureTemplates.js +2 -0
- package/dist/commands/install/helpers/templates/edgeTemplates.js +4 -0
- package/dist/commands/install/istioAgents.js +8 -1
- package/dist/common/types.js +33 -2
- package/package.json +22 -23
- package/renovate.json +5 -1
|
@@ -119,7 +119,8 @@ const agents = {
|
|
|
119
119
|
console.log(_chalk.default.gray(`This command configures and installs the agents so that you can manage your gateway environment within the Amplify Platform.\n`));
|
|
120
120
|
let installConfig = new _types.AgentInstallConfig();
|
|
121
121
|
installConfig.centralConfig.axwayManaged = !!axwayManaged;
|
|
122
|
-
installConfig.centralConfig.region = region ? region.toString() : _types.Regions.US;
|
|
122
|
+
installConfig.centralConfig.region = region ? region.toString() : _types.Regions.US;
|
|
123
|
+
installConfig.centralConfig.singleEntryPointUrl = _types.SingleEntryPointUrls[installConfig.centralConfig.region]; // gateway type
|
|
123
124
|
|
|
124
125
|
let gatewayType = await (0, _basicPrompts.askList)({
|
|
125
126
|
msg: prompts.selectGatewayType,
|
|
@@ -91,6 +91,7 @@ CENTRAL_AUTH_PUBLICKEY={{centralConfig.dosaAccount.templatePublicKey}}
|
|
|
91
91
|
CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
92
92
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
93
93
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
94
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
94
95
|
{{#compare . centralConfig.region "EU"}}
|
|
95
96
|
CENTRAL_URL={{centralConfig.url}}
|
|
96
97
|
CENTRAL_DEPLOYMENT={{centralConfig.deployment}}
|
|
@@ -143,6 +144,7 @@ CENTRAL_AUTH_PUBLICKEY={{centralConfig.dosaAccount.templatePublicKey}}
|
|
|
143
144
|
CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
144
145
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
145
146
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
147
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
146
148
|
{{#compare . centralConfig.region "EU"}}
|
|
147
149
|
CENTRAL_URL={{centralConfig.url}}
|
|
148
150
|
{{/compare}}
|
|
@@ -86,6 +86,7 @@ CENTRAL_AUTH_PUBLICKEY={{centralConfig.dosaAccount.templatePublicKey}}
|
|
|
86
86
|
CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
87
87
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
88
88
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
89
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
89
90
|
{{#compare . centralConfig.region "EU"}}
|
|
90
91
|
CENTRAL_URL={{centralConfig.url}}
|
|
91
92
|
CENTRAL_DEPLOYMENT={{centralConfig.deployment}}
|
|
@@ -135,6 +136,7 @@ CENTRAL_AUTH_PUBLICKEY={{centralConfig.dosaAccount.templatePublicKey}}
|
|
|
135
136
|
CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
136
137
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
137
138
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
139
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
138
140
|
{{#compare . centralConfig.region "EU"}}
|
|
139
141
|
CENTRAL_URL={{centralConfig.url}}
|
|
140
142
|
{{/compare}}
|
|
@@ -127,6 +127,7 @@ CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
|
127
127
|
{{#compare . centralConfig.ampcTeamName "" operator="!=" }}
|
|
128
128
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
129
129
|
{{/compare}}
|
|
130
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
130
131
|
{{#compare . centralConfig.region "EU"}}
|
|
131
132
|
CENTRAL_URL={{centralConfig.url}}
|
|
132
133
|
CENTRAL_DEPLOYMENT={{centralConfig.deployment}}
|
|
@@ -195,6 +196,7 @@ env:
|
|
|
195
196
|
{{#compare . centralConfig.ampcTeamName "" operator="!=" }}
|
|
196
197
|
CENTRAL_TEAM: {{centralConfig.ampcTeamName}}
|
|
197
198
|
{{/compare}}
|
|
199
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
198
200
|
CENTRAL_URL: {{centralConfig.url}}
|
|
199
201
|
EVENT_LOG_FILE_PATHS: /events/*.log
|
|
200
202
|
LOG_LEVEL: info
|
|
@@ -268,6 +270,7 @@ CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
|
268
270
|
{{#compare . centralConfig.ampcTeamName "" operator="!=" }}
|
|
269
271
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
270
272
|
{{/compare}}
|
|
273
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
271
274
|
{{#compare . centralConfig.region "EU"}}
|
|
272
275
|
CENTRAL_URL={{centralConfig.url}}
|
|
273
276
|
{{/compare}}
|
|
@@ -319,6 +322,7 @@ env:
|
|
|
319
322
|
{{#compare . centralConfig.ampcTeamName "" operator="!=" }}
|
|
320
323
|
CENTRAL_TEAM: {{centralConfig.ampcTeamName}}
|
|
321
324
|
{{/compare}}
|
|
325
|
+
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
322
326
|
CENTRAL_URL: {{centralConfig.url}}
|
|
323
327
|
LOG_LEVEL: info
|
|
324
328
|
|
|
@@ -71,6 +71,7 @@ const istioPrompts = {
|
|
|
71
71
|
enterCertificatePath: 'Enter the file path to the certificate',
|
|
72
72
|
existingIstioPrompt: 'Use existing Istio installation?',
|
|
73
73
|
askGatewayNamespace: 'Select the namespace where the Istio ingress gateway is running',
|
|
74
|
+
profilePrompt: 'Select the Istio profile to use',
|
|
74
75
|
// kubernetes
|
|
75
76
|
enterMeshAgentNamespace: 'Enter the namespace to use for the Amplify Istio Agents',
|
|
76
77
|
alsModePrompt: 'Select Traceability Agent HTTP header publishing mode',
|
|
@@ -168,6 +169,11 @@ const askCertificateOption = async () => (0, _basicPrompts.askList)({
|
|
|
168
169
|
name: 'Provide certificate',
|
|
169
170
|
value: _types.Certificate.PROVIDE
|
|
170
171
|
}]
|
|
172
|
+
});
|
|
173
|
+
|
|
174
|
+
const askIstioProfile = async () => (0, _basicPrompts.askList)({
|
|
175
|
+
msg: istioPrompts.profilePrompt,
|
|
176
|
+
choices: _types.IstioProfileChoices
|
|
171
177
|
}); //Setup Overrides
|
|
172
178
|
|
|
173
179
|
|
|
@@ -185,6 +191,7 @@ const setupIstio = async istioValues => {
|
|
|
185
191
|
return istioInstallValues;
|
|
186
192
|
}
|
|
187
193
|
|
|
194
|
+
istioInstallValues.profile = await askIstioProfile();
|
|
188
195
|
console.log(_chalk.default.gray('\nFor a Kubernetes cluster exposing HTTPS endpoints, you must own or be able to configure a certificate for the correspoinding fully qualified domain name\n'));
|
|
189
196
|
istioInstallValues.host = (await askHost()).toLowerCase();
|
|
190
197
|
|
|
@@ -329,7 +336,7 @@ const createIstioOverride = overrides => {
|
|
|
329
336
|
console.log(`\nIstio override file has been placed at ${process.cwd()}/${overrideFileName}`);
|
|
330
337
|
|
|
331
338
|
if (overrides.istioInstallValues.isNewInstall) {
|
|
332
|
-
console.log('To complete the istio installation run the following command:', _chalk.default.cyan(`\n istioctl install --set profile
|
|
339
|
+
console.log('To complete the istio installation run the following command:', _chalk.default.cyan(`\n istioctl install --set profile=${overrides.istioInstallValues.profile} -f ${overrideFileName}\n`));
|
|
333
340
|
} else {
|
|
334
341
|
console.log(_chalk.default.cyan(` Please merge the generated ${overrideFileName} file with your Istio configuration to allow the Traceability Agent to function.\n`));
|
|
335
342
|
}
|
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.TraceabilityConfig = exports.Regions = exports.PublicRepoUrl = exports.PublicDockerRepoBaseUrl = exports.Protocol = exports.ProdBaseUrls = exports.Platforms = exports.OutputTypes = exports.MAX_FILE_SIZE = exports.MAX_CACHE_FILE_SIZE = exports.LoggingSource = exports.KindTypes = exports.Kind = exports.IstioInstallValues = exports.IstioAgentValues = exports.IngestionProtocolToHosts = exports.IngestionProtocol = exports.IngestionHostsHTTP = exports.IngestionHosts = exports.IngestionHTTPHosts = 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.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.TraceabilityConfig = exports.SingleEntryPointUrls = exports.Regions = exports.PublicRepoUrl = exports.PublicDockerRepoBaseUrl = exports.Protocol = exports.ProdBaseUrls = exports.Platforms = exports.OutputTypes = exports.MAX_FILE_SIZE = exports.MAX_CACHE_FILE_SIZE = exports.LoggingSource = exports.KindTypes = exports.Kind = exports.IstioProfileChoices = exports.IstioInstallValues = exports.IstioAgentValues = exports.IngestionProtocolToHosts = exports.IngestionProtocol = exports.IngestionHostsHTTP = exports.IngestionHosts = exports.IngestionHTTPHosts = 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.APICDeployments = exports.ABORT_TIMEOUT = void 0;
|
|
7
7
|
|
|
8
8
|
var _dataService = require("./dataService");
|
|
9
9
|
|
|
@@ -84,6 +84,11 @@ exports.AuthUrls = AuthUrls;
|
|
|
84
84
|
AuthUrls["Prod"] = "https://login.axway.com";
|
|
85
85
|
})(AuthUrls || (exports.AuthUrls = AuthUrls = {}));
|
|
86
86
|
|
|
87
|
+
const SingleEntryPointUrls = {
|
|
88
|
+
US: 'https://ingestion.platform.axway.com',
|
|
89
|
+
EU: 'https://ingestion-eu.platform.axway.com'
|
|
90
|
+
};
|
|
91
|
+
exports.SingleEntryPointUrls = SingleEntryPointUrls;
|
|
87
92
|
let Regions;
|
|
88
93
|
exports.Regions = Regions;
|
|
89
94
|
|
|
@@ -203,6 +208,26 @@ const YesNoChoices = [{
|
|
|
203
208
|
value: YesNo.No
|
|
204
209
|
}];
|
|
205
210
|
exports.YesNoChoices = YesNoChoices;
|
|
211
|
+
const IstioProfileChoices = [{
|
|
212
|
+
name: 'default',
|
|
213
|
+
value: 'default'
|
|
214
|
+
}, {
|
|
215
|
+
name: 'demo',
|
|
216
|
+
value: 'demo'
|
|
217
|
+
}, {
|
|
218
|
+
name: 'empty',
|
|
219
|
+
value: 'empty'
|
|
220
|
+
}, {
|
|
221
|
+
name: 'minimal',
|
|
222
|
+
value: 'minimal'
|
|
223
|
+
}, {
|
|
224
|
+
name: 'openshift',
|
|
225
|
+
value: 'openshift'
|
|
226
|
+
}, {
|
|
227
|
+
name: 'preview',
|
|
228
|
+
value: 'preview'
|
|
229
|
+
}];
|
|
230
|
+
exports.IstioProfileChoices = IstioProfileChoices;
|
|
206
231
|
// exporting for tests
|
|
207
232
|
let AgentConfigTypes;
|
|
208
233
|
exports.AgentConfigTypes = AgentConfigTypes;
|
|
@@ -363,6 +388,8 @@ class CentralAgentConfig {
|
|
|
363
388
|
|
|
364
389
|
_defineProperty(this, "host", void 0);
|
|
365
390
|
|
|
391
|
+
_defineProperty(this, "singleEntryPointUrl", void 0);
|
|
392
|
+
|
|
366
393
|
_defineProperty(this, "scheme", void 0);
|
|
367
394
|
|
|
368
395
|
_defineProperty(this, "production", void 0);
|
|
@@ -391,6 +418,7 @@ class CentralAgentConfig {
|
|
|
391
418
|
[this.scheme, this.host] = this.url.split('://');
|
|
392
419
|
this.production = false;
|
|
393
420
|
this.axwayManaged = false;
|
|
421
|
+
this.singleEntryPointUrl = SingleEntryPointUrls[this.region];
|
|
394
422
|
}
|
|
395
423
|
|
|
396
424
|
}
|
|
@@ -712,20 +740,23 @@ class IstioInstallValues {
|
|
|
712
740
|
|
|
713
741
|
_defineProperty(this, "protocol", void 0);
|
|
714
742
|
|
|
743
|
+
_defineProperty(this, "profile", void 0);
|
|
744
|
+
|
|
715
745
|
_defineProperty(this, "targetPort", void 0);
|
|
716
746
|
|
|
717
747
|
_defineProperty(this, "certificateOption", void 0);
|
|
718
748
|
|
|
719
749
|
this.alsNamespace = 'amplify-agents';
|
|
750
|
+
this.certificateOption = '';
|
|
720
751
|
this.enableAls = false;
|
|
721
752
|
this.enableTracing = false;
|
|
722
753
|
this.gatewayNamespace = 'istio-system';
|
|
723
754
|
this.host = '';
|
|
724
755
|
this.isNewInstall = true;
|
|
725
756
|
this.port = 8080;
|
|
757
|
+
this.profile = 'demo';
|
|
726
758
|
this.protocol = Protocol.HTTP;
|
|
727
759
|
this.targetPort = 0;
|
|
728
|
-
this.certificateOption = '';
|
|
729
760
|
}
|
|
730
761
|
|
|
731
762
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@axway/axway-central-cli",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.3",
|
|
4
4
|
"description": "Manage APIs, services and publish to the Unified Catalog",
|
|
5
5
|
"homepage": "https://platform.axway.com",
|
|
6
6
|
"author": {
|
|
@@ -41,43 +41,42 @@
|
|
|
41
41
|
"name": "central"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@axway/amplify-cli-utils": "^5.0.
|
|
44
|
+
"@axway/amplify-cli-utils": "^5.0.9",
|
|
45
45
|
"chalk": "^4.1.2",
|
|
46
|
-
"cli-kit": "^1.
|
|
47
|
-
"dayjs": "^1.11.
|
|
46
|
+
"cli-kit": "^1.16.0",
|
|
47
|
+
"dayjs": "^1.11.2",
|
|
48
48
|
"easy-table": "^1.2.0",
|
|
49
49
|
"extract-zip": "^2.0.1",
|
|
50
50
|
"form-data": "^4.0.0",
|
|
51
|
-
"fs-extra": "^10.0
|
|
52
|
-
"g": "^2.0.1",
|
|
51
|
+
"fs-extra": "^10.1.0",
|
|
53
52
|
"handlebars": "^4.7.7",
|
|
54
|
-
"inquirer": "^8.2.
|
|
53
|
+
"inquirer": "^8.2.4",
|
|
55
54
|
"js-yaml": "^4.1.0",
|
|
56
55
|
"lodash": "^4.17.21",
|
|
57
56
|
"node-cache": "^5.1.2",
|
|
58
|
-
"npm-check-updates": "^12.5.
|
|
57
|
+
"npm-check-updates": "^12.5.12",
|
|
59
58
|
"ora": "^5.4.1",
|
|
60
59
|
"promise-limit": "^2.7.0",
|
|
61
|
-
"semver": "^7.3.
|
|
60
|
+
"semver": "^7.3.7",
|
|
62
61
|
"snooplogg": "^3.0.2",
|
|
63
62
|
"tmp": "^0.2.1"
|
|
64
63
|
},
|
|
65
64
|
"devDependencies": {
|
|
66
|
-
"@babel/cli": "^7.17.
|
|
67
|
-
"@babel/core": "^7.
|
|
68
|
-
"@babel/plugin-proposal-class-properties": "^7.
|
|
69
|
-
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.
|
|
70
|
-
"@babel/plugin-proposal-optional-chaining": "^7.
|
|
71
|
-
"@babel/preset-env": "^7.
|
|
72
|
-
"@babel/preset-typescript": "^7.
|
|
73
|
-
"@types/chai": "^4.3.
|
|
65
|
+
"@babel/cli": "^7.17.10",
|
|
66
|
+
"@babel/core": "^7.18.0",
|
|
67
|
+
"@babel/plugin-proposal-class-properties": "^7.17.12",
|
|
68
|
+
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.17.12",
|
|
69
|
+
"@babel/plugin-proposal-optional-chaining": "^7.17.12",
|
|
70
|
+
"@babel/preset-env": "^7.18.0",
|
|
71
|
+
"@babel/preset-typescript": "^7.17.12",
|
|
72
|
+
"@types/chai": "^4.3.1",
|
|
74
73
|
"@types/chai-as-promised": "^7.1.5",
|
|
75
74
|
"@types/form-data": "^2.5.0",
|
|
76
75
|
"@types/fs-extra": "^9.0.13",
|
|
77
76
|
"@types/inquirer": "^8.2.1",
|
|
78
77
|
"@types/js-yaml": "^4.0.5",
|
|
79
|
-
"@types/lodash": "^4.14.
|
|
80
|
-
"@types/mocha": "^9.1.
|
|
78
|
+
"@types/lodash": "^4.14.182",
|
|
79
|
+
"@types/mocha": "^9.1.1",
|
|
81
80
|
"@types/node": "^17.0.23",
|
|
82
81
|
"@types/rx": "^4.1.2",
|
|
83
82
|
"@types/semver": "^7.3.9",
|
|
@@ -88,16 +87,16 @@
|
|
|
88
87
|
"babel-plugin-lodash": "^3.3.4",
|
|
89
88
|
"chai": "^4.3.6",
|
|
90
89
|
"chai-as-promised": "^7.1.1",
|
|
91
|
-
"core-js": "^3.
|
|
90
|
+
"core-js": "^3.22.5",
|
|
92
91
|
"mocha": "^9.2.2",
|
|
93
92
|
"nock": "^13.2.4",
|
|
94
|
-
"nodemon": "^2.0.
|
|
93
|
+
"nodemon": "^2.0.16",
|
|
95
94
|
"nyc": "^15.1.0",
|
|
96
95
|
"prettier": "^2.6.2",
|
|
97
96
|
"sinon": "^11.1.2",
|
|
98
97
|
"source-map-support": "^0.5.21",
|
|
99
|
-
"ts-mocha": "^
|
|
100
|
-
"typescript": "^4.6.
|
|
98
|
+
"ts-mocha": "^10.0.0",
|
|
99
|
+
"typescript": "^4.6.4"
|
|
101
100
|
},
|
|
102
101
|
"jest": {
|
|
103
102
|
"verbose": true,
|
package/renovate.json
CHANGED
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
"extends": [
|
|
4
4
|
"config:base"
|
|
5
5
|
],
|
|
6
|
+
"branchPrefix": "APIGOV-renovate-",
|
|
7
|
+
"commitMessagePrefix": "APIGOV-renovate -",
|
|
8
|
+
"onboardingBranch": "ConfigureRenovate",
|
|
9
|
+
"rangeStrategy": "bump",
|
|
6
10
|
"prConcurrentLimit": 0,
|
|
7
|
-
"
|
|
11
|
+
"prHourlyLimit": 0
|
|
8
12
|
}
|