Update container
Update a specific container in your server.
PATCH/api/servers/{server}/docker/containers/{container}
Update a container
This endpoint allows you to update an existing Docker container on your server.
Optional attributes
- Name
name- Type
- string
- Description
The new name of the container.
- Name
deploy_script- Type
- string
- Description
Docker compose configuration in YAML format.
Request
PATCH
/api/servers/{server}/docker/containers/{container}curl -X PATCH "https://ploi.io/api/servers/{server}/docker/containers/1" \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{"name":"new-name"}'
Response
{
"id": 3,
"status": "active",
"name": "postgres-database",
"deploy_script": "version: '3'\nservices:\n db:\n image: postgres:16\n environment:\n POSTGRES_PASSWORD: example\n POSTGRES_USER: ploi\n ports:\n - '5432:5432'",
"path": "/home/ploi/containers/postgres-database",
"last_deploy_at": null,
"created_at": "2025-04-01T10:30:00.000000Z",
"type": "docker",
"state": "stopped"
}