すべてのプロダクト
Search
ドキュメントセンター

Resource Orchestration Service:ALIYUN::SWAS::Instance

最終更新日:Mar 17, 2025

ALIYUN::SWAS::Instance は、サブスクリプション型のシンプルアプリケーションサーバーを作成するために使用されます。

構文

{
  "Type": "ALIYUN::SWAS::Instance",
  "Properties": {
    "AutoRenewPeriod": Integer,
    "PlanId": String,
    "AutoRenew": Boolean,
    "ImageId": String,
    "Period": Integer,
    "DataDiskSize": Integer
  }
}

プロパティ

プロパティ

タイプ

必須

編集可能

説明

制約

AutoRenewPeriod

Integer

いいえ

いいえ

シンプルアプリケーションサーバーの自動更新期間。

単位:月。

有効な値:1、3、6、12、24、および 36。

このプロパティは、AutoRenew が true に設定されている場合にのみ指定する必要があります。

PlanId

String

はい

いいえ

プラン ID。

ListPlans 操作を呼び出すことで、指定したリージョン内のすべてのプランに関する情報をクエリできます。

AutoRenew

Boolean

いいえ

いいえ

自動更新を有効にするかどうかを指定します。

有効な値:

  • true

  • false (デフォルト)

ImageId

String

はい

いいえ

イメージ ID。

ListImages 操作を呼び出すことで、指定したリージョンで使用可能なイメージの ID をクエリできます。

Period

Integer

はい

いいえ

シンプルアプリケーションサーバーのサブスクリプション期間。

単位:月。

有効な値:1、3、6、12、24、および 36。

DataDiskSize

Integer

いいえ

いいえ

シンプルアプリケーションサーバーにアタッチするデータディスクのサイズ。

単位:GB。

有効な値:0 ~ 16380。値は 20 の倍数である必要があります。

  • 値 0 は、データディスクがアタッチされていないことを示します。

  • 指定されたプランにパフォーマンスレベル 0 (PL0) の拡張 SSD (ESSD) が含まれている場合、データディスクのサイズは 40 GB 以上である必要があります。

  • 指定されたプランに標準 SSD が含まれている場合、データディスクのサイズは 20 GB 以上である必要があります。

デフォルト値:0。

戻り値

Fn::GetAtt

  • PublicIpAddress:シンプルアプリケーションサーバーのパブリック IP アドレス。

  • InnerIpAddress:シンプルアプリケーションサーバーのプライベート IP アドレス。

  • InstanceId:シンプルアプリケーションサーバーの ID。

  • YAML フォーマット

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      AutoRenew:
        Description:
          en: 'Specifies whether to enable auto-renewal. Valid values:
            true
            false
            Default value: false.'
        Type: Boolean
      AutoRenewPeriod:
        Description:
          en: 'The auto-renewal period. This parameter is required only when you set AutoRenew
            to true. Unit: months. Valid values: 1, 3, 6, 12, 24, and 36.'
        Type: Number
      DataDiskSize:
        Description:
          en: 'The size of the data disk that is attached to the server. Unit: GB. Valid
            values: 0 to 16380. The value must be an integral multiple of 20.
            A value of 0 indicates that no data disk is attached.
            If the disk included in the specified plan is a standard SSD, the data disk
            must be 20 GB or larger in size.
            Default value: 0.'
        Type: Number
      ImageId:
        Description:
          en: The image ID. You can call the ListImages operation to query the available
            images in the specified region.
        Type: String
        Default: fe9c66133a9d4688872869726b52****
      Period:
        Description:
          en: 'The subscription period of the servers. Unit: months. Valid values: 1,
            3, 6, 12, 24, and 36.'
        Type: Number
      PlanId:
        Description:
          en: The plan ID. You can call the ListPlans operation to query all plans provided
            by Simple Application Server in the specified region.
        Type: String
        Default: swas.s2.c2m1s40b3t04 
    Resources:
      Instance:
        Properties:
          AutoRenew:
            Ref: AutoRenew
          AutoRenewPeriod:
            Ref: AutoRenewPeriod
          DataDiskSize:
            Ref: DataDiskSize
          ImageId:
            Ref: ImageId
          Period:
            Ref: Period
          PlanId:
            Ref: PlanId
        Type: ALIYUN::SWAS::Instance
    Outputs:
      InnerIpAddress:
        Description: The inner IP address of simple application server.
        Value:
          Fn::GetAtt:
          - Instance
          - InnerIpAddress
      InstanceId:
        Description: The ID of the simple application server.
        Value:
          Fn::GetAtt:
          - Instance
          - InstanceId
      PublicIpAddress:
        Description: The public IP address of simple application server.
        Value:
          Fn::GetAtt:
          - Instance
          - PublicIpAddress
  • JSON フォーマット

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "AutoRenew": {
          "Description": {
            "en": "Specifies whether to enable auto-renewal. Valid values: true false Default value: false."
          },
          "Type": "Boolean"
        },
        "AutoRenewPeriod": {
          "Description": {
            "en": "The auto-renewal period. This parameter is required only when you set AutoRenew to true. Unit: months. Valid values: 1, 3, 6, 12, 24, and 36."
          },
          "Type": "Number"
        },
        "DataDiskSize": {
          "Description": {
            "en": "The size of the data disk that is attached to the server. Unit: GB. Valid values: 0 to 16380. The value must be an integral multiple of 20. A value of 0 indicates that no data disk is attached. If the disk included in the specified plan is a standard SSD, the data disk must be 20 GB or larger in size. Default value: 0."
          },
          "Type": "Number"
        },
        "ImageId": {
          "Description": {
            "en": "The image ID. You can call the ListImages operation to query the available images in the specified region."
          },
          "Type": "String",
          "Default": "fe9c66133a9d4688872869726b52****"
        },
        "Period": {
          "Description": {
            "en": "The subscription period of the servers. Unit: months. Valid values: 1, 3, 6, 12, 24, and 36."
          },
          "Type": "Number"
        },
        "PlanId": {
          "Description": {
            "en": "The plan ID. You can call the ListPlans operation to query all plans provided by Simple Application Server in the specified region."
          },
          "Type": "String",
          "Default": "swas.s2.c2m1s40b3t04"
        }
      },
      "Resources": {
        "Instance": {
          "Properties": {
            "AutoRenew": {
              "Ref": "AutoRenew"
            },
            "AutoRenewPeriod": {
              "Ref": "AutoRenewPeriod"
            },
            "DataDiskSize": {
              "Ref": "DataDiskSize"
            },
            "ImageId": {
              "Ref": "ImageId"
            },
            "Period": {
              "Ref": "Period"
            },
            "PlanId": {
              "Ref": "PlanId"
            }
          },
          "Type": "ALIYUN::SWAS::Instance"
        }
      },
      "Outputs": {
        "InnerIpAddress": {
          "Description": "The inner IP address of simple application server.",
          "Value": {
            "Fn::GetAtt": [
              "Instance",
              "InnerIpAddress"
            ]
          }
        },
        "InstanceId": {
          "Description": "The ID of the simple application server.",
          "Value": {
            "Fn::GetAtt": [
              "Instance",
              "InstanceId"
            ]
          }
        },
        "PublicIpAddress": {
          "Description": "The public IP address of simple application server.",
          "Value": {
            "Fn::GetAtt": [
              "Instance",
              "PublicIpAddress"
            ]
          }
        }
      }
    }