remove authCode (scope should suffice), add org and env to bundles.
diff --git a/apidGatewayDeploy-api.yaml b/apidGatewayDeploy-api.yaml
index b6cb86c..c48ca40 100644
--- a/apidGatewayDeploy-api.yaml
+++ b/apidGatewayDeploy-api.yaml
@@ -46,16 +46,22 @@
"bundles": [
{
"bundleId": "system-bundle-rev-3",
- "authCode": "@#$nike#$#$stage&#$(^#",
- "uri": "file:///apid/bundles/system-bundle-release-1-1233.zip"
+ "uri": "file:///apid/bundles/system-bundle-release-1-1233.zip",
+ "scope": "@#$nike#$#$stage&#$(^#",
+ "org": "nike",
+ "env": "stage",
},{
"bundleId": "bundleA-rev-9",
- "authCode": "@#$nike#$#$prod&#$(^#",
- "uri": "file:///apid/bundles/bundleA-rev-9-26372.zip"
+ "uri": "file:///apid/bundles/bundleA-rev-9-26372.zip",
+ "scope": "@#$nike#$#$prod&#$(^#",
+ "org": "nike",
+ "env": "prod",
},{
"bundleId": "bundleB-rev-1",
- "authCode": "@#$nike#$#$test&#$(^#",
- "uri": "file:///somewhere/bundles/bundleB-rev-1-72351.zip"
+ "uri": "file:///somewhere/bundles/bundleB-rev-1-72351.zip",
+ "scope": "@#$nike#$#$test&#$(^#",
+ "org": "nike",
+ "env": "test",
}
]
}
@@ -126,20 +132,28 @@
type: object
required:
- bundleId
- - url
+ - uri
properties:
bundleId:
type: string
- url:
+ uri:
type: string
+
UserBundle:
allOf:
- $ref: '#/definitions/SystemBundle'
required:
- - authCode
+ - scope
properties:
- authCode:
+ scope:
type: string
+ description: Used to convey request scope information to APID APIs
+ org:
+ type: string
+ description: Available for legacy purposes
+ env:
+ type: string
+ description: Available for legacy purposes
DeploymentResult:
type: object
@@ -158,7 +172,6 @@
"status": "SUCCESS"
}
-
DeploymentResultError:
type: object
required:
@@ -176,7 +189,7 @@
example: {
"error": {
"errorCode": 5,
- "reason": "Failed to restart NGINX",
+ "reason": "Failed restart",
"bundleErrors": [
{
"bundleId": "system-bundle-rev-3",
diff --git a/deployments.go b/deployments.go
index 90c2068..3115217 100644
--- a/deployments.go
+++ b/deployments.go
@@ -24,6 +24,8 @@
type dependantBundle struct {
URI string `json:"uri"`
Scope string `json:"scope"`
+ Org string `json:"org"`
+ Env string `json:"env"`
}
type bundleManifest struct {