GET/stacks/:stack_id/containers/:container_id
Get Containeradmin
Required Parameters
stack_id
stringThe stack UID
container_id
stringThe container UID
Get information of a container of the stack (includes container runtime information).
Related Models:Container
Request
GET
/stacks/:stack_id/containers/:container_idcurl -X GET \
"https://app.cloud66.com/api/3/stacks/:stack_id/containers/:container_id" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json"
Response
{
"response": {
"uid": "cba44fa6b6acf57fb0ef6c2ce385f6a129867df544dae7181d2410e9f9cc32bc",
"server_uid": "c6014897b8c8e9f2fc204a3a9efdae05",
"server_name": "Gazelle",
"service_name": "web",
"image": "quay.io/cloud66/sample-rails",
"command": "bundle exec rackup -p 3000",
"started_at": "2015-02-10T17:41:31Z",
"ports": [
{
"container": 3000,
"http": 80,
"https": 443
}
],
"private_ip": "25.0.0.2",
"docker_ip": null,
"health_state": 1,
"health_message": null,
"health_source": "system",
"capture_output": true,
"restart_on_deploy": true,
"created_at": "2015-02-10T17:41:37Z",
"updated_at": "2015-02-17T14:40:17Z"
}
}
GET/stacks/:stack_id/containers
List Containerspublic
Required Parameters
stack_id
stringThe stack UID
Optional Parameters
server_uid
stringServer UID
Get a list of all the containers of the stack.
Request
GET
/stacks/:stack_id/containerscurl -X GET \
"https://app.cloud66.com/api/3/stacks/:stack_id/containers?server_uid=c6014897b8c8e9f2fc204a3a9efdae05" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json"
Response
{
"response": [
{
"uid": "cba44fa6b6acf57fb0ef6c2ce385f6a129867df544dae7181d2410e9f9cc32bc",
"server_uid": "c6014897b8c8e9f2fc204a3a9efdae05",
"server_name": "Gazelle",
"service_name": "web",
"image": "quay.io/cloud66/sample-rails",
"command": "bundle exec rackup -p 3000",
"started_at": "2015-02-10T17:41:31Z",
"ports": [
{
"container": 3000,
"http": 80,
"https": 443
}
],
"private_ip": "25.0.0.2",
"docker_ip": null,
"health_state": 1,
"health_message": null,
"health_source": "system",
"capture_output": true,
"restart_on_deploy": true,
"created_at": "2015-02-10T17:41:37Z",
"updated_at": "2015-02-17T14:40:17Z"
}
],
"count": 1,
"pagination": {
"previous": null,
"next": null,
"current": 1,
"per_page": 30,
"count": 1,
"pages": 1
}
}
DELETE/stacks/:stack_id/containers/:container_id
Stop Containeradmin
Required Parameters
stack_id
stringThe stack UID
container_id
stringThe container UID
Stop a container of the stack.
Related Models:Container
Request
DELETE
/stacks/:stack_id/containers/:container_idcurl -X DELETE \
"https://app.cloud66.com/api/3/stacks/:stack_id/containers/:container_id" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json"
Response
{
"response": {
"ok": true
}
}