@axway/axway-central-cli 2.12.4 → 2.14.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.
- package/README.md +6 -2
- package/dist/commands/config/set.js +1 -1
- package/dist/commands/install/helpers/getters.js +16 -0
- package/dist/commands/install/helpers/templates/awsTemplates.js +2 -2
- package/dist/commands/install/helpers/templates/azureTemplates.js +2 -2
- package/dist/commands/install/helpers/templates/edgeTemplates.js +2 -2
- package/dist/commands/install/istioAgents.js +8 -0
- package/dist/commands/install/platform.js +4 -0
- package/dist/common/CoreConfigController.js +1 -1
- package/dist/common/types.js +16 -7
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -148,16 +148,20 @@ CONFIG COMMANDS:
|
|
|
148
148
|
|
|
149
149
|
### Region configuration
|
|
150
150
|
|
|
151
|
-
Region configuration identifies the Amplify Central instance whose servers you want to send your requests
|
|
151
|
+
Region configuration identifies the Amplify Central instance to whose servers you want to send your requests. Your current authenticated account's org setting is used by default (i.e., if your org belongs to the APAC region, it is going to be used automatically).
|
|
152
|
+
|
|
153
|
+
You can always override the current region setting by configuring CLI with the following command (possible values are `US`, `EU` or `AP`):
|
|
152
154
|
|
|
153
155
|
```bash
|
|
154
156
|
# to point CLI to EU region:
|
|
155
157
|
axway central config set --region=EU
|
|
156
158
|
# to point CLI to US region:
|
|
157
159
|
axway central config set --region=US
|
|
160
|
+
# to point CLI to APAC region:
|
|
161
|
+
axway central config set --region=AP
|
|
158
162
|
```
|
|
159
163
|
|
|
160
|
-
|
|
164
|
+
Or by adding optional `--region=<value>` flag with any command:
|
|
161
165
|
|
|
162
166
|
```bash
|
|
163
167
|
axway central get environments --region=EU
|
|
@@ -82,7 +82,7 @@ const action = async ({
|
|
|
82
82
|
log(`Writing ${_types.ConfigTypes.APIC_DEPLOYMENT}`);
|
|
83
83
|
|
|
84
84
|
if (!Object.values(_types.APICDeployments).includes(argv.apicDeployment)) {
|
|
85
|
-
throw Error('"--apic-deployment" value is not correct, please provide one of: prod, staging, prod-eu, staging-eu, qa, or teams. For example: "axway central config set --apic-deployment=staging"');
|
|
85
|
+
throw Error('"--apic-deployment" value is not correct, please provide one of: prod, staging, prod-ap, prod-eu, staging-eu, qa, or teams. For example: "axway central config set --apic-deployment=staging"');
|
|
86
86
|
}
|
|
87
87
|
|
|
88
88
|
config[_types.ConfigTypes.APIC_DEPLOYMENT] = argv.apicDeployment;
|
|
@@ -86,6 +86,14 @@ const getIngestionHost = (region, env, apicDeployment, protocol = _types.Ingesti
|
|
|
86
86
|
[_types.Platforms.staging]: {
|
|
87
87
|
[_types.APICDeployments.EUStaging]: _types.IngestionHosts.EUStaging
|
|
88
88
|
}
|
|
89
|
+
},
|
|
90
|
+
[_types.Regions.AP]: {
|
|
91
|
+
[_types.Platforms.prod]: {
|
|
92
|
+
[_types.APICDeployments.AP]: _types.IngestionHosts.AP
|
|
93
|
+
},
|
|
94
|
+
[_types.Platforms.staging]: {
|
|
95
|
+
[_types.APICDeployments.APStaging]: _types.IngestionHosts.APStaging
|
|
96
|
+
}
|
|
89
97
|
}
|
|
90
98
|
},
|
|
91
99
|
[_types.IngestionProtocol.HTTPS]: {
|
|
@@ -104,6 +112,14 @@ const getIngestionHost = (region, env, apicDeployment, protocol = _types.Ingesti
|
|
|
104
112
|
[_types.Platforms.staging]: {
|
|
105
113
|
[_types.APICDeployments.EU]: _types.IngestionHTTPHosts.EUStaging
|
|
106
114
|
}
|
|
115
|
+
},
|
|
116
|
+
[_types.Regions.AP]: {
|
|
117
|
+
[_types.Platforms.prod]: {
|
|
118
|
+
[_types.APICDeployments.AP]: _types.IngestionHTTPHosts.AP
|
|
119
|
+
},
|
|
120
|
+
[_types.Platforms.staging]: {
|
|
121
|
+
[_types.APICDeployments.AP]: _types.IngestionHTTPHosts.APStaging
|
|
122
|
+
}
|
|
107
123
|
}
|
|
108
124
|
}
|
|
109
125
|
};
|
|
@@ -92,7 +92,7 @@ CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
|
92
92
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
93
93
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
94
94
|
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
95
|
-
{{#compare . centralConfig.region "
|
|
95
|
+
{{#compare . centralConfig.region "US" operator="!="}}
|
|
96
96
|
CENTRAL_URL={{centralConfig.url}}
|
|
97
97
|
CENTRAL_DEPLOYMENT={{centralConfig.deployment}}
|
|
98
98
|
|
|
@@ -145,7 +145,7 @@ CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
|
145
145
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
146
146
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
147
147
|
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
148
|
-
{{#compare . centralConfig.region "
|
|
148
|
+
{{#compare . centralConfig.region "US" operator="!="}}
|
|
149
149
|
CENTRAL_URL={{centralConfig.url}}
|
|
150
150
|
{{/compare}}
|
|
151
151
|
|
|
@@ -87,7 +87,7 @@ CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
|
87
87
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
88
88
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
89
89
|
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
90
|
-
{{#compare . centralConfig.region "
|
|
90
|
+
{{#compare . centralConfig.region "US" operator="!="}}
|
|
91
91
|
CENTRAL_URL={{centralConfig.url}}
|
|
92
92
|
CENTRAL_DEPLOYMENT={{centralConfig.deployment}}
|
|
93
93
|
|
|
@@ -137,7 +137,7 @@ CENTRAL_ENVIRONMENT={{centralConfig.environment}}
|
|
|
137
137
|
CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
138
138
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
139
139
|
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
140
|
-
{{#compare . centralConfig.region "
|
|
140
|
+
{{#compare . centralConfig.region "US" operator="!="}}
|
|
141
141
|
CENTRAL_URL={{centralConfig.url}}
|
|
142
142
|
{{/compare}}
|
|
143
143
|
|
|
@@ -134,7 +134,7 @@ CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
|
134
134
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
135
135
|
{{/compare}}
|
|
136
136
|
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
137
|
-
{{#compare . centralConfig.region "
|
|
137
|
+
{{#compare . centralConfig.region "US" operator="!="}}
|
|
138
138
|
CENTRAL_URL={{centralConfig.url}}
|
|
139
139
|
CENTRAL_DEPLOYMENT={{centralConfig.deployment}}
|
|
140
140
|
|
|
@@ -305,7 +305,7 @@ CENTRAL_ORGANIZATIONID={{centralConfig.orgId}}
|
|
|
305
305
|
CENTRAL_TEAM={{centralConfig.ampcTeamName}}
|
|
306
306
|
{{/compare}}
|
|
307
307
|
CENTRAL_SINGLEURL={{centralConfig.singleEntryPointUrl}}
|
|
308
|
-
{{#compare . centralConfig.region "
|
|
308
|
+
{{#compare . centralConfig.region "US" operator="!="}}
|
|
309
309
|
CENTRAL_URL={{centralConfig.url}}
|
|
310
310
|
{{/compare}}
|
|
311
311
|
|
|
@@ -343,6 +343,14 @@ const getCondorHost = (region, env, apicDeployment) => {
|
|
|
343
343
|
[_types.Platforms.staging]: {
|
|
344
344
|
[_types.APICDeployments.EUStaging]: _types.IngestionHosts.EUStaging
|
|
345
345
|
}
|
|
346
|
+
},
|
|
347
|
+
[_types.Regions.AP]: {
|
|
348
|
+
[_types.Platforms.prod]: {
|
|
349
|
+
[_types.APICDeployments.AP]: _types.IngestionHosts.AP
|
|
350
|
+
},
|
|
351
|
+
[_types.Platforms.staging]: {
|
|
352
|
+
[_types.APICDeployments.APStaging]: _types.IngestionHosts.APStaging
|
|
353
|
+
}
|
|
346
354
|
}
|
|
347
355
|
};
|
|
348
356
|
return ((_hosts$region = hosts[region]) === null || _hosts$region === void 0 ? void 0 : (_hosts$region$env = _hosts$region[env]) === null || _hosts$region$env === void 0 ? void 0 : _hosts$region$env[apicDeployment]) || _types.IngestionHosts.US;
|
|
@@ -179,6 +179,10 @@ const getApicDeployment = (region, env) => {
|
|
|
179
179
|
[_types.Regions.EU]: {
|
|
180
180
|
[_types.Platforms.prod]: _types.APICDeployments.EU,
|
|
181
181
|
[_types.Platforms.staging]: _types.APICDeployments.EUStaging
|
|
182
|
+
},
|
|
183
|
+
[_types.Regions.AP]: {
|
|
184
|
+
[_types.Platforms.prod]: _types.APICDeployments.AP,
|
|
185
|
+
[_types.Platforms.staging]: _types.APICDeployments.APStaging
|
|
182
186
|
}
|
|
183
187
|
};
|
|
184
188
|
const savedDeployment = new _CliConfigManager.CliConfigManager().getAll()['apic-deployment'];
|
|
@@ -73,7 +73,7 @@ class CoreConfigController {
|
|
|
73
73
|
const baseUrl = process.env.AXWAY_CENTRAL_BASE_URL || configCtrl.get(_CliConfigManager.CliConfigKeys.BASE_URL); // environment defined by using central cli "base-url" or axway "env" configs if set,
|
|
74
74
|
// otherwise its undefined (equals to prod)
|
|
75
75
|
|
|
76
|
-
const environment = !baseUrl || baseUrl === _types.ProdBaseUrls.US || baseUrl === _types.ProdBaseUrls.EU ? config.get('env') : 'staging';
|
|
76
|
+
const environment = !baseUrl || baseUrl === _types.ProdBaseUrls.US || baseUrl === _types.ProdBaseUrls.EU || baseUrl === _types.ProdBaseUrls.AP ? config.get('env') : 'staging';
|
|
77
77
|
log(`getAuthInfo, baseUrl = ${baseUrl}, environment = ${environment}`);
|
|
78
78
|
const {
|
|
79
79
|
sdk
|
package/dist/common/types.js
CHANGED
|
@@ -88,7 +88,8 @@ exports.AuthUrls = AuthUrls;
|
|
|
88
88
|
|
|
89
89
|
const SingleEntryPointUrls = {
|
|
90
90
|
US: 'https://ingestion.platform.axway.com',
|
|
91
|
-
EU: 'https://ingestion-eu.platform.axway.com'
|
|
91
|
+
EU: 'https://ingestion-eu.platform.axway.com',
|
|
92
|
+
AP: 'https://ingestion-ap-sg.platform.axway.com'
|
|
92
93
|
};
|
|
93
94
|
exports.SingleEntryPointUrls = SingleEntryPointUrls;
|
|
94
95
|
let Regions;
|
|
@@ -97,6 +98,7 @@ exports.Regions = Regions;
|
|
|
97
98
|
(function (Regions) {
|
|
98
99
|
Regions["US"] = "US";
|
|
99
100
|
Regions["EU"] = "EU";
|
|
101
|
+
Regions["AP"] = "AP";
|
|
100
102
|
})(Regions || (exports.Regions = Regions = {}));
|
|
101
103
|
|
|
102
104
|
let Platforms;
|
|
@@ -109,8 +111,8 @@ exports.Platforms = Platforms;
|
|
|
109
111
|
|
|
110
112
|
const ProdBaseUrls = {
|
|
111
113
|
US: 'https://apicentral.axway.com',
|
|
112
|
-
|
|
113
|
-
|
|
114
|
+
EU: 'https://central.eu-fr.axway.com',
|
|
115
|
+
AP: 'https://central.ap-sg.axway.com'
|
|
114
116
|
};
|
|
115
117
|
exports.ProdBaseUrls = ProdBaseUrls;
|
|
116
118
|
let IngestionProtocol;
|
|
@@ -126,19 +128,24 @@ const IngestionHosts = {
|
|
|
126
128
|
EUStaging: 'ingestion.visibility.eu-fr.axwaypreprod.net:5044',
|
|
127
129
|
QA: 'ingestion.condor.staging.axwaytest.net:5044',
|
|
128
130
|
US: 'ingestion.datasearch.axway.com:5044',
|
|
129
|
-
USStaging: 'ingestion.search.axwaytest.net:5044'
|
|
131
|
+
USStaging: 'ingestion.search.axwaytest.net:5044',
|
|
132
|
+
AP: 'ingestion.visibility.ap-sg.axway.com:5044',
|
|
133
|
+
APStaging: 'ingestion.visibility.ap-sg.axwaypreprod.net:5044'
|
|
130
134
|
};
|
|
131
135
|
exports.IngestionHosts = IngestionHosts;
|
|
132
136
|
const IngestionHTTPHosts = {
|
|
133
137
|
US: 'ingestion.datasearch.axway.com:443',
|
|
134
138
|
USStaging: 'ingestion.search.axwaytest.net:443',
|
|
135
139
|
EU: 'ingestion.visibility.eu-fr.axway.com:443',
|
|
136
|
-
EUStaging: 'ingestion.visibility.eu-fr.axwaypreprod.net:443'
|
|
140
|
+
EUStaging: 'ingestion.visibility.eu-fr.axwaypreprod.net:443',
|
|
141
|
+
AP: 'ingestion.visibility.ap-sg.axway.com:443',
|
|
142
|
+
APStaging: 'ingestion.visibility.ap-sg.axwaypreprod.net:443'
|
|
137
143
|
};
|
|
138
144
|
exports.IngestionHTTPHosts = IngestionHTTPHosts;
|
|
139
145
|
const IngestionHostsHTTP = {
|
|
140
146
|
US: 'ingestion.datasearch.axway.com:443',
|
|
141
|
-
EU: 'ingestion.visibility.eu-fr.axway.com:443'
|
|
147
|
+
EU: 'ingestion.visibility.eu-fr.axway.com:443',
|
|
148
|
+
AP: 'ingestion.visibility.ap-sg.axway.com:443'
|
|
142
149
|
};
|
|
143
150
|
exports.IngestionHostsHTTP = IngestionHostsHTTP;
|
|
144
151
|
const IngestionProtocolToHosts = {
|
|
@@ -152,7 +159,9 @@ const APICDeployments = {
|
|
|
152
159
|
QA: 'qa',
|
|
153
160
|
US: 'prod',
|
|
154
161
|
USStaging: 'staging',
|
|
155
|
-
TEAMS: 'teams'
|
|
162
|
+
TEAMS: 'teams',
|
|
163
|
+
AP: 'prod-ap',
|
|
164
|
+
APStaging: 'preprod'
|
|
156
165
|
};
|
|
157
166
|
exports.APICDeployments = APICDeployments;
|
|
158
167
|
const commonCmdArgsDescription = {
|