Return Git deployment task status

This function retrieves the status of deployment tasks. Before deployment, repositories must meet the following requirements:

  • A valid checked-in .cpanel.yml file in the top-level directory.
  • One or more local or remote branches.
  • A clean working tree.

If a repository does not meet these requirements, the system will not display deployment information. Also, it will disable deployment functionality. For more information, read our Guide to Git™ - Deployment documentation.

Important:

The system logs messages for this function in the ~/.cpanel/logs/vc_TIMESTAMP_git_deploy.log file, where TIMESTAMP represents the time in Unix epoch time.

SecurityBasicAuth
Responses
200

HTTP Request was successful.

Response Schema: application/json
apiversion
integer

The version of the API.

func
string

The name of the method called.

module
string

The name of the module called.

object
get/VersionControlDeployment/retrieve
Request samples
uapi --output=jsonpretty \
  --user=username \
  VersionControlDeployment \
  retrieve
Response samples
application/json
{
  • "apiversion": 3,
  • "func": "retrieve",
  • "module": "VersionControlDeployment",
  • "result": {
    • "data": [
      • {
        • "deploy_id": 13,
        • "log_path": "/home/user/.cpanel/logs/vc_1525289448.759720_git_deploy.log",
        • "repository_root": "/home/username/example",
        • "repository_state": {
          • "author": "Jane Doe <jane.doe@example.com>",
          • "branch": "master",
          • "date": 1410277881,
          • "identifier": "2fd4e1c67a2d28fced849ee1bb76e7391b93eb12",
          • "message": "This is a commit."
          },
        • "sse_url": "/sse/UserTasks/B3A27B96-51F7-11E8-92E3-CC90C4F823F0",
        • "task_id": "00000000/5aea11e886a5d8",
        • "timestamps": {
          • "active": "1525289448.83553",
          • "canceled": "1525289448.83553",
          • "failed": "1525289448.83553",
          • "queued": "1525289448.83553",
          • "succeeded": "1525289448.83553"
          }
        }
      ],
    • "errors": null,
    • "messages": null,
    • "metadata": { },
    • "status": 1,
    • "warnings": null
    }
}