Updated on 2025-02-14 GMT+08:00

Deploying a Component

In this example, the component is deployed in the environment.

Overview

This example uses the API for deploying a component.

For details about how to call APIs, see 3 Calling APIs.

Procedure

  1. Deploy a component.

    Call the API for deploying a component. The following shows an example request.

    curl -k -H "Content-Type:application/json" -H "X-Environment-ID: $env_id" -H "X-Auth-Token:$Token" -X POST "https://{cae_endpoint}v1/{project_id}/cae/applications/{application_id}/components/{component_id}/action" -d '{
        "api_version": "v1",
        "kind": "Action",
        "metadata": {
            "name": "deploy",
            "annotations": {
               "version": "1.0.0"
            }
        }
    }
    '

    Information similar to the following is displayed.

    {
    "job_id": "68531a56-febe-4218-be23-97fe00454cd1"
    }

    You can obtain the deployment status based on the obtained job_id.