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

Resource Orchestration Service:アーキテクチャテンプレートとして ROS テンプレートをインポートする

最終更新日:Nov 14, 2025

この Topic では、既存の Resource Orchestration Service (ROS) テンプレートをインポートしてアーキテクチャ図を作成する方法について説明します。

説明
  • ROS テンプレートにレイアウト情報が含まれていない場合、ROS Architecture Editor はアルゴリズムに基づいてリソースレイアウトを自動的に配置します。自動レイアウトの品質は、テンプレートの複雑さによって異なります。

  • 複雑なテンプレートをインポートする場合、アーキテクチャ図を最適化するためにリソースレイアウトを手動で調整する必要がある場合があります。

前提条件

ROS テンプレートが必要です。テンプレートを作成するには、「テンプレートクイックスタート」をご参照ください。

ソリューションを検証するには、次のサンプルテンプレートを使用して、Elastic IP アドレス (EIP) と ECS インスタンスを作成します。

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  Zone:
    Type: String
    AssociationProperty: ALIYUN::ECS::Instance::ZoneId
    AssociationPropertyMetadata:
      WithAvailableResource: true
      DefaultValueStrategy: first
    Label:
      en: VSwitch Availability Zone
    Default: cn-beijing-f
Resources:
  VPC:
    Type: ALIYUN::ECS::VPC
    Properties:
      CidrBlock: 10.0.0.0/8
      EnableIpv6: false
  VSwitch:
    Type: ALIYUN::ECS::VSwitch
    Properties:
      ZoneId:
        Ref: Zone
      VpcId:
        Ref: VPC
      CidrBlock: 10.0.0.0/24
  SecurityGroup:
    Type: ALIYUN::ECS::SecurityGroup
    Properties:
      VpcId:
        Ref: VPC
  ECSInstance:
    Type: ALIYUN::ECS::Instance
    Properties:
      VSwitchId:
        Ref: VSwitch
      ZoneId:
        Ref: Zone
      VpcId:
        Ref: VPC
      SecurityGroupIds:
        - Ref: SecurityGroup
      SystemDiskSize: 40
      InstanceChargeType: PostPaid
      AllocatePublicIP: false
      IoOptimized: optimized
      ImageId: aliyun_3_x64_20G_qboot_alibase_20230727.vhd
      SystemDiskCategory: cloud_efficiency
      InstanceType: ecs.t5-lc2m1.nano
  EIP:
    Type: ALIYUN::VPC::EIP
    Properties:
      Isp: BGP
      DeletionProtection: false
      Netmode: public
      InstanceChargeType: PayAsYouGo
      InternetChargeType: PayByBandwidth
      Bandwidth: 5
  EIPAssociation:
    Type: ALIYUN::VPC::EIPAssociation
    Properties:
      AllocationId:
        Ref: EIP
      InstanceId:
        Ref: ECSInstance
      Mode: NAT
Metadata:
  ALIYUN::ROS::Composer:
    67cb9fc3:
      Rect:
        - 632
        - 588
        - -184
        - -217
        - 0
        - 0
      ResT: Composer::ROSParameter::AlibabaCloud
      Label: AlibabaCloud
    67cb9fc4:
      Parent: 67cb9fc3
      Rect:
        - 598
        - 523
        - -164
        - -172
        - 1
        - 0
      Reg: cn-beijing
      ResT: Composer::ROSParameter::Region
      Label: Region
    4ce1a0a6:
      Res:
        - Zone
      Parent: fe688e94
      Rect:
        - 520
        - 320
        - -124
        - -9
        - 3
        - 0
      ResT: Composer::ROSParameter::Zone
      Label: Zone
    fe688e94:
      Res:
        - VPC
      Parent: 67cb9fc4
      Rect:
        - 560
        - 400
        - -144
        - -69
        - 2
        - 0
      Label: VPC
    a8e63de3:
      Res:
        - VSwitch
      Parent: 4ce1a0a6
      Rect:
        - 480
        - 240
        - -104
        - 51
        - 4
        - 0
      Label: vSwitch
    d6a407f2:
      Res:
        - SecurityGroup
      Parent: fe688e94
      Rect:
        - 160
        - 120
        - 30
        - 145
        - 10
        - 0
      Label: Security group
    6d7f85e4:
      Res:
        - ECSInstance
      Parent: a8e63de3
      Rect:
        - 40
        - 40
        - 90
        - 185
        - 11
        - 0
      Layer:
        - d6a407f2
      Label: ECS instance
    69c24097:
      Res:
        - EIP
        - EIPAssociation
      Parent: 67cb9fc4
      Rect:
        - 40
        - 40
        - 90
        - -150
        - 2
        - 0
      Label: EIP
    52dd50ee-a0c0-4d13-a3e3-df80fb4c4aa9:
      Parent: 67cb9fc4
      Edge:
        - 69c24097
        - 6d7f85e4
      Line: 0:0:0:#969696:0

手順

  1. ROS Architecture Editor コンソールにログインします。

  2. 左側のナビゲーションウィンドウで、[アーキテクチャテンプレート] をクリックします。

  3. [アーキテクチャテンプレート] ページで、[アーキテクチャテンプレートの作成] をクリックします。ダイアログボックスで [ROS] または [Terraform] を選択し、[OK] をクリックします。

    説明

    ROS テンプレートのみをインポートできます。Terraform テンプレートはサポートされていません。

  4. アーキテクチャテンプレートエディターページで、左上隅にある image.png アイコンをクリックします。ドロップダウンメニューで、[テンプレートコンテンツのインポート] をクリックします。

  5. [テンプレートコンテンツのインポート] ダイアログボックスで、テンプレートコンテンツをエディターに貼り付けて [OK] をクリックします。ROS Architecture Editor は、テンプレートコンテンツに基づいてアーキテクチャ図を自動的にレンダリングします。次の図に例を示します。

    image.png