@axway/axway-central-cli 2.3.0 → 2.5.1
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/README.md +60 -52
- package/dist/commands/apply/index.js +10 -4
- package/dist/commands/config/set.js +12 -7
- package/dist/commands/create/agentResource.js +6 -2
- package/dist/commands/create/environment.js +13 -16
- package/dist/commands/create/index.js +11 -5
- package/dist/commands/create/serviceAccount.js +5 -43
- package/dist/commands/delete/index.js +30 -10
- package/dist/commands/edit/environment.js +17 -18
- package/dist/commands/get/index.js +7 -2
- package/dist/commands/install/agents.js +17 -4
- package/dist/commands/install/helpers/inputs.js +19 -8
- package/dist/commands/install/helpers/templates/istioTemplates.js +6 -0
- package/dist/commands/install/platform.js +9 -12
- package/dist/commands/proxies/create.js +2 -0
- package/dist/commands/proxies/index.js +1 -0
- package/dist/commands/proxies/promote.js +2 -0
- package/dist/common/ApiCentralClient.js +11 -7
- package/dist/common/ApiServerClient.js +24 -19
- package/dist/common/CliConfigManager.js +22 -2
- package/dist/common/CoreConfigController.js +65 -42
- package/dist/common/PlatformClient.js +9 -5
- package/dist/common/Renderer.js +6 -6
- package/dist/common/dataService.js +2 -2
- package/dist/common/errorHandler.js +2 -5
- package/dist/common/types.js +3 -5
- package/package.json +5 -3
|
@@ -7,8 +7,8 @@ exports.handleErrors = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _cliKit = require("cli-kit");
|
|
9
9
|
|
|
10
|
-
// TODO:
|
|
11
|
-
//
|
|
10
|
+
// TODO: used by legacy "proxies" command only, will be removed soon
|
|
11
|
+
// https://jira.axway.com/browse/APIGOV-20818
|
|
12
12
|
const handleErrors = (console, e, spinner) => {
|
|
13
13
|
if (e.errors && Array.isArray(e.errors)) {
|
|
14
14
|
const error = e.errors[0];
|
|
@@ -21,9 +21,6 @@ const handleErrors = (console, e, spinner) => {
|
|
|
21
21
|
console.info((0, _cliKit.chalk)`{cyan axway auth login}`);
|
|
22
22
|
console.info('Or if using a service account:');
|
|
23
23
|
console.info((0, _cliKit.chalk)`{cyan axway auth login --client-id <Service Account Client ID> --secret-file <Private Key>}`);
|
|
24
|
-
console.info((0, _cliKit.chalk)`{cyan axway central config set --client-id=<Service Account Client ID>}`);
|
|
25
|
-
console.info(`Or if no longer using a service account:`);
|
|
26
|
-
console.info((0, _cliKit.chalk)`{cyan axway central config unset client-id}`);
|
|
27
24
|
break;
|
|
28
25
|
|
|
29
26
|
case 403:
|
package/dist/common/types.js
CHANGED
|
@@ -3,14 +3,12 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.docsUrl = exports.
|
|
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;
|
|
7
7
|
|
|
8
8
|
var _dataService = require("./dataService");
|
|
9
9
|
|
|
10
10
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
11
11
|
|
|
12
|
-
const defaultClientId = 'amplify-cli';
|
|
13
|
-
exports.defaultClientId = defaultClientId;
|
|
14
12
|
const cliVersionHeader = 'x-axway-cli-version';
|
|
15
13
|
exports.cliVersionHeader = cliVersionHeader;
|
|
16
14
|
const docsUrl = 'https://docs.axway.com/bundle/axway-open-docs/page/docs/central/index.html';
|
|
@@ -71,11 +69,11 @@ exports.ConfigTypes = ConfigTypes;
|
|
|
71
69
|
(function (ConfigTypes) {
|
|
72
70
|
ConfigTypes["APIC_DEPLOYMENT"] = "apic-deployment";
|
|
73
71
|
ConfigTypes["BASE_URL"] = "base-url";
|
|
74
|
-
ConfigTypes["CLIENT_ID"] = "client-id";
|
|
75
72
|
ConfigTypes["EXTENSIONS"] = "extensions";
|
|
76
73
|
ConfigTypes["REGION"] = "region";
|
|
77
74
|
ConfigTypes["PLATFORM"] = "platform";
|
|
78
75
|
ConfigTypes["AXWAY_MANAGED"] = "axway-managed";
|
|
76
|
+
ConfigTypes["CLIENT_ID"] = "client-id";
|
|
79
77
|
})(ConfigTypes || (exports.ConfigTypes = ConfigTypes = {}));
|
|
80
78
|
|
|
81
79
|
let AuthUrls;
|
|
@@ -151,7 +149,7 @@ const APICDeployments = {
|
|
|
151
149
|
};
|
|
152
150
|
exports.APICDeployments = APICDeployments;
|
|
153
151
|
const commonCmdArgsDescription = {
|
|
154
|
-
'--
|
|
152
|
+
'--account [value]': `Override your default account config`,
|
|
155
153
|
'--region [value]': `Override your region config`,
|
|
156
154
|
'--no-cache': `Do not use cache when communicating with the server`,
|
|
157
155
|
'--base-url [value]': {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@axway/axway-central-cli",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.5.1",
|
|
4
4
|
"description": "Manage APIs, services and publish to the Unified Catalog",
|
|
5
5
|
"homepage": "https://platform.axway.com",
|
|
6
6
|
"author": {
|
|
@@ -26,7 +26,8 @@
|
|
|
26
26
|
"scripts": {
|
|
27
27
|
"build": "babel src --extensions .ts -d dist --ignore src/**/*.spec.ts,src/**/*.spec.js",
|
|
28
28
|
"test": "ts-mocha --timeout 10000",
|
|
29
|
-
"test:
|
|
29
|
+
"test:cov": "nyc yarn test",
|
|
30
|
+
"test:c": "yarn test:cov",
|
|
30
31
|
"test:w": "yarn test -w --watch-extensions ts",
|
|
31
32
|
"type-check": "tsc -p tsconfig.build.json",
|
|
32
33
|
"start": "nodemon --watch src -e yaml,ts,js,json -i *.spec.ts --exec npm run build"
|
|
@@ -40,7 +41,7 @@
|
|
|
40
41
|
"name": "central"
|
|
41
42
|
},
|
|
42
43
|
"dependencies": {
|
|
43
|
-
"@axway/amplify-cli-utils": "^5.0.
|
|
44
|
+
"@axway/amplify-cli-utils": "^5.0.3",
|
|
44
45
|
"chalk": "^4.1.2",
|
|
45
46
|
"cli-kit": "^1.14.1",
|
|
46
47
|
"dayjs": "^1.10.7",
|
|
@@ -67,6 +68,7 @@
|
|
|
67
68
|
"@babel/preset-env": "^7.15.8",
|
|
68
69
|
"@babel/preset-typescript": "^7.15.0",
|
|
69
70
|
"@types/chai": "^4.2.22",
|
|
71
|
+
"@types/chai-as-promised": "^7.1.4",
|
|
70
72
|
"@types/easy-table": "^0.0.33",
|
|
71
73
|
"@types/form-data": "^2.5.0",
|
|
72
74
|
"@types/fs-extra": "^9.0.13",
|