diff options
author | 2018-09-04 20:32:50 +0000 | |
---|---|---|
committer | 2018-09-04 20:32:50 +0000 | |
commit | 7e9b8b6967a69ae04a37dcba5448c3017fc91d51 (patch) | |
tree | f2fe2201e2215694f330b17d14c38cf8cabee59b /docs | |
parent | 6e2857125fdce17a1541f3ca45ee0b988e9ef4de (diff) | |
parent | 9ea39f64e077613fe004ed00f7b2b2497381faea (diff) |
Merge "Update docs to include sample commands"
Diffstat (limited to 'docs')
-rw-r--r-- | docs/sampleCommands.rst | 88 |
1 files changed, 60 insertions, 28 deletions
diff --git a/docs/sampleCommands.rst b/docs/sampleCommands.rst index 2407b260..c635c250 100644 --- a/docs/sampleCommands.rst +++ b/docs/sampleCommands.rst @@ -17,7 +17,7 @@ Sample cURL commands POST **** -URL: `localhost:8081/v1/vnf_instances/cloudregion1/namespacetest` +URL: `localhost:8081/v1/vnf_instances/` Request Body ------------ @@ -26,6 +26,7 @@ Request Body { "cloud_region_id": "region1", + "namespace": "test-namespace", "csar_id": "uuid", "namespace": "test", "oof_parameters": [{ @@ -48,37 +49,68 @@ Expected Response .. code-block:: json { - "response": "Created Deployment:nginx-deployment" + "vnf_id": "52fdfc07", + "cloud_region_id": "cloudregion1", + "namespace": "test-namespace", + "vnf_components": { + "deployment": [ + "cloudregion1-test-namespace-52fdfc07-kubedeployment" + ], + "service": [ + "cloudregion1-test-namespace-52fdfc07-kubeservice" + ] + } } -The above POST request will download the following YAML file and run it on the Kubernetes cluster. - -.. code-block:: yaml - - apiVersion: apps/v1 - kind: Deployment - metadata: - name: nginx-deployment - labels: - app: nginx - spec: - replicas: 3 - selector: - matchLabels: - app: nginx - template: - metadata: - labels: - app: nginx - spec: - containers: - - name: nginx - image: nginx:1.7.9 - ports: - - containerPort: 80 - *** GET *** URL: `localhost:8081/v1/vnf_instances` + +Expected Response +----------------- + +.. code-block:: json + + { + "vnf_id_list": [ + "52fdfc07" + ] + } + +*** +GET +*** + +URL: `localhost:8081/v1/vnf_instances/cloudregion1/test-namespace/52fdfc07` + +Expected Response +----------------- + +.. code-block:: json + + { + "vnf_id": "52fdfc07", + "cloud_region_id": "cloudregion1", + "namespace": "test-namespace", + "vnf_components": { + "deployment": [ + "cloudregion1-test-namespace-52fdfc07-kubedeployment" + ], + "service": [ + "cloudregion1-test-namespace-52fdfc07-kubeservice" + ] + } + } + +*** +DELETE +*** + +URL: `localhost:8081/v1/vnf_instances/cloudregion1/test-namespace/52fdfc07` + +Expected Response +----------------- + +202 Accepted
\ No newline at end of file |