I want to use a single edge.json file for my API products, Developers and Apps across my non-prod and prod orgs, each having different environments. Here’s the org level portion of my edge.json
"orgConfig": {
"apiProducts": [
{
"name": "template-v1-product-cicd",
"apiResources": [
"/",
"/**"
],
"approvalType": "auto",
"attributes": [
{
"name": "description",
"value": "Product to test template API for CI/CD"
}
],
"description": "Product to test template-v1 API",
"displayName": "template-v1-product-cicd",
"environments": [
"dev", "qa", "stage",
"sandbox", "prod"
],
"proxies": [
"identity-v1",
"template-v1"
],
"quota": "10000",
"quotaInterval": "1",
"quotaTimeUnit": "month",
"scopes": []
}
]
}
In my case dev, qa and stage are in non-prod org and sandbox and prod are in prod org.
When I run:
mvn apigee-config:apiproducts -Psandbox -Dapigee.config.options=update
I get the error:
[ERROR] {
[ERROR] "code" : "keymanagement.service.InvalidEnvironment",
[ERROR] "message" : "Invalid environment dev",
[ERROR] "contexts" : [ ]
[ERROR] }
which is as expected, but how do I achieve what I want?
It seems there ought to be a similar structure as per envConfig which allows me to specify the environment name
"envConfig": {
"dev": {
"targetServers": []
Anyone else doing this?