All Products
Search
Document Center

Resource Orchestration Service:ALIYUN::CS::ApplicationDeployment

更新时间:Jan 10, 2025

ALIYUN::CS::ApplicationDeployment is used to deploy an application.

Syntax

{
  "Type": "ALIYUN::CS::ApplicationDeployment",
  "Properties": {
    "ClusterId": String,
    "ChartUrl": String,
    "Namespace": String,
    "Name": String,
    "Type": String,
    "Values": Map
  }
}

Properties

Property

Type

Required

Editable

Description

Constraint

ClusterId

String

Yes

No

The ID of the cluster.

None.

ChartUrl

String

Yes

No

The request URL of the chart.

None.

Namespace

String

Yes

No

The namespace of the application.

None.

Name

String

Yes

No

The name of the application.

None.

Type

String

Yes

No

The type of the application that can be deployed.

  • Set the value to helm.

Values

Map

No

No

The custom values of the application.

None.

Return values

Fn::GetAtt

TaskId: the ID of the task that is run to deploy the application.

Examples

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  Type:
    Type: String
    Description:
      en: Type of the deployed application, currently can only be helm.
    AllowedValues:
      - helm
    Required: true
  ClusterId:
    Type: String
    Description:
      en: The cluster id of the deployed application.
    Required: true
    AssociationProperty: ALIYUN::CS::Cluster::ClusterId
  ChartUrl:
    Type: String
    Description:
      en: Helm chart package URL, must be a valid URL.
    Required: true
    Default: https://aliacs-app-catalog.oss-cn-hangzhou.aliyuncs.com/charts-incubator/ack-knative-kourier-1.4.0.tgz
  Namespace:
    Type: String
    Description:
      en: Deployment namespace.
    Required: true
    MinLength: 3
    MaxLength: 64
    Default: knative-serving
  Name:
    Type: String
    Description:
      en: Name of the deployed application.
    Required: true
    MinLength: 3
    MaxLength: 64
    Default: knative-kourier
Resources:
  ApplicationDeployment:
    Type: ALIYUN::CS::ApplicationDeployment
    Properties:
      Type:
        Ref: Type
      ClusterId:
        Ref: ClusterId
      Values:
        version: v1.10.9-aliyun.1
        regionID:
          Ref: ALIYUN::Region
      ChartUrl:
        Ref: ChartUrl
      Namespace:
        Ref: Namespace
      Name:
        Ref: Name
Outputs:
  TaskId:
    Description: The task ID of the application deployment.
    Value:
      Fn::GetAtt:
        - ApplicationDeployment
        - TaskId
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "Type": {
      "Type": "String",
      "Description": {
        "en": "Type of the deployed application, currently can only be helm."
      },
      "AllowedValues": [
        "helm"
      ],
      "Required": true
    },
    "ClusterId": {
      "Type": "String",
      "Description": {
        "en": "The cluster id of the deployed application."
      },
      "Required": true,
      "AssociationProperty": "ALIYUN::CS::Cluster::ClusterId"
    },
    "ChartUrl": {
      "Type": "String",
      "Description": {
        "en": "Helm chart package URL, must be a valid URL."
      },
      "Required": true,
      "Default": "https://aliacs-app-catalog.oss-cn-hangzhou.aliyuncs.com/charts-incubator/ack-knative-kourier-1.4.0.tgz"
    },
    "Namespace": {
      "Type": "String",
      "Description": {
        "en": "Deployment namespace."
      },
      "Required": true,
      "MinLength": 3,
      "MaxLength": 64,
      "Default": "knative-serving"
    },
    "Name": {
      "Type": "String",
      "Description": {
        "en": "Name of the deployed application."
      },
      "Required": true,
      "MinLength": 3,
      "MaxLength": 64,
      "Default": "knative-kourier"
    }
  },
  "Resources": {
    "ApplicationDeployment": {
      "Type": "ALIYUN::CS::ApplicationDeployment",
      "Properties": {
        "Type": {
          "Ref": "Type"
        },
        "ClusterId": {
          "Ref": "ClusterId"
        },
        "Values": {
          "version": "v1.10.9-aliyun.1",
          "regionID": {
            "Ref": "ALIYUN::Region"
          }
        },
        "ChartUrl": {
          "Ref": "ChartUrl"
        },
        "Namespace": {
          "Ref": "Namespace"
        },
        "Name": {
          "Ref": "Name"
        }
      }
    }
  },
  "Outputs": {
    "TaskId": {
      "Description": "The task ID of the application deployment.",
      "Value": {
        "Fn::GetAtt": [
          "ApplicationDeployment",
          "TaskId"
        ]
      }
    }
  }
}