corestack_ enterprise_ deployment_ trigger
Deploy on a CoreStack Enterprise environment.
When to use it
Deploy on a CoreStack Enterprise environment, one of two ways:
- Start a waiting deployment (
deployment_id): an environment that deploys git pushes by hand keeps each push waiting (pending) until someone presses Deploy. This is that button: the deployment is built from its pipeline as it is now, or on another pipeline of the environment (pipeline_id). - Deploy a commit (
repository_id+commit): a new deployment of that commit of one of the environment's repositories, through the pipeline the repository deploys with.
A task follows the deployment to its end; poll it, or read corestack_enterprise_deployment_get. Cancelling the task
cancels the deployment. Uploading a release archive is the public API's POST /
(a file body); the same two ways are its POST …/deployments/{deployment}/run and the same POST with git.
Ask for it
Using the Corefinity MCP server, call corestack_enterprise_deployment_trigger with enterprise_env_id 1530, repository_id 812, commit 4f2c9a1e0b7d3c5a6e8f9b0c1d2e3f4a5b6c7d8e, notes Hotfix for the checkout page. (Deploy on a CoreStack Enterprise environment.) Tell me what it returned.Inputs
With repository_id
A waiting deployment to start. At least 1.
A CoreStack Enterprise environment's id; for CoreStack or CoreCluster use the corestack_deployment_* tools. At least 1.
With a commit only Up to 255 characters.
With a commit only Up to 10,000 characters.
With deployment_id only, another pipeline of the environment to start it on At least 1.
With commit, a new deployment of that repository of the environment At least 1.
Give deployment_id, or repository_id and commit: never both, never neither.
Example call
{
"name": "corestack_enterprise_deployment_trigger",
"arguments": {
"enterprise_env_id": 1530,
"repository_id": 812,
"commit": "4f2c9a1e0b7d3c5a6e8f9b0c1d2e3f4a5b6c7d8e",
"notes": "Hotfix for the checkout page"
}
}If it is refused
| Reason | What to do |
|---|---|
invalid_arguments | Neither or both ways given, pipeline_id with a commit, a commit that is not a full SHA, or a repository that is not this environment's (field repository_id); a CoreStack or CoreCluster environment (field enterprise_env_id). |
stale | That deployment is not waiting any more, or the environment has already moved past it, or the pipeline chosen — for a commit, the pipeline its repository deploys with — is no longer available in the environment. Read it again. |
busy | The same start is still being applied. forbidden: the person's role lacks the Create Deployments permission (Deploy Deployments to start a waiting deployment). The message names it and says an owner of the company can grant it in Roles; details.permission is createDeployments (or deployDeployments). |
no_namespace | The environment has no namespace on its cluster, so there is nothing to deploy to. Nothing is created; the Control Panel's Deploy form and the REST API refuse it in the same words. Staff must look at the environment. |
tenant_mismatch | The object does not exist or the token may not see it. Check the id. |
pin_refused | The grant is limited to chosen clusters, sites or environments, and this call is outside them. Open the link in the answer to widen it. |
scope_required | The token lacks a scope this call needs. Open the link in the answer to add it, then call again. |
rate_limited | Too many calls. Wait for the number of seconds the answer names. |
temporarily_unavailable | The Control Panel could not answer just now. Nothing was started; try again shortly. |
internal_error | Something went wrong on our side. Quote the trace id to support. |