Skip to content

Commit

Permalink
Update testing.rst
Browse files Browse the repository at this point in the history
  • Loading branch information
fcarp10 committed Jan 31, 2019
1 parent 50f669b commit a1c67e0
Showing 1 changed file with 21 additions and 7 deletions.
28 changes: 21 additions & 7 deletions documentation/developer_guide/testing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -125,24 +125,38 @@ To get a specific resource, use its unique ID:
Create a new service
~~~~~~~~~~~~~~~~~~~~

Example with only required fields:

.. code-block:: bash
mf2c-curl-post https://localhost/api/service -d '''
{
"name": "compss-hello-world",
"exec": "mf2c/compss-test:it2",
"exec_type": "compss",
"agent_type": "normal"
}'''
Example with all optional fields:

.. code-block:: bash
mf2c-curl-post https://localhost/api/service -d '''
{
"name": "hello-world",
"name": "compss-hello-world",
"description": "Hello World Service",
"exec": "hello-world",
"exec_type": "docker",
"exec": "mf2c/compss-test:it2",
"exec_type": "compss",
"exec_ports": [8080],
"agent_type": "cloud",
"agent_type": "normal",
"num_agents": "2",
"cpu_arch": "x86-64",
"os": "linux",
"memory_min": 1000,
"storage_min": 100,
"disk": 100,
"req_resource": ["Location", "Sentinel", "Ambulance"],
"opt_resource": ["SenseHat", "GP-20U7"],
"category": 3
"req_resource": ["Location"],
"opt_resource": ["SenseHat"]
}'''
Create a service instance
Expand Down

0 comments on commit a1c67e0

Please sign in to comment.