All Products
Search
Document Center

Resource Orchestration Service:ALIYUN::BastionHost::PasswordTaskHostAccountAttachment

Last Updated:Apr 09, 2026

The ALIYUN::BastionHost::PasswordTaskHostAccountAttachment resource attaches host accounts to a password task.

Syntax

{
  "Type": "ALIYUN::BastionHost::PasswordTaskHostAccountAttachment",
  "Properties": {
    "HostAccountIds": List,
    "InstanceId": String,
    "TaskId": String
  }
}

Properties

Property name

Type

Required

Update allowed

Description

Constraints

HostAccountIds

List

Yes

No

The IDs of the host accounts to attach to the password task.

None

InstanceId

String

Yes

No

The ID of the bastion host instance.

None

TaskId

String

Yes

No

The ID of the password task.

None

Return values

Fn::GetAtt

This resource does not have any return values.

Examples

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  TaskId:
    Type: String
    Description:
      en: The ID of the password task.
    Required: true
  InstanceId:
    Type: String
    Description:
      en: The ID of the bastion host instance.
    Required: true
  HostAccountIds:
    AssociationPropertyMetadata:
      Parameter:
        Type: String
        Required: false
    AssociationProperty: List[Parameter]
    Type: Json
    Description:
      en: The IDs of the host accounts to be attached to the password task.
    Required: true
Resources:
  PasswordTaskHostAccountAttachment:
    Type: ALIYUN::BastionHost::PasswordTaskHostAccountAttachment
    Properties:
      TaskId:
        Ref: TaskId
      InstanceId:
        Ref: InstanceId
      HostAccountIds:
        Ref: HostAccountIds
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "TaskId": {
      "Type": "String",
      "Description": {
        "en": "The ID of the password task."
      },
      "Required": true
    },
    "InstanceId": {
      "Type": "String",
      "Description": {
        "en": "The ID of the bastion host instance."
      },
      "Required": true
    },
    "HostAccountIds": {
      "AssociationPropertyMetadata": {
        "Parameter": {
          "Type": "String",
          "Required": false
        }
      },
      "AssociationProperty": "List[Parameter]",
      "Type": "Json",
      "Description": {
        "en": "The IDs of the host accounts to be attached to the password task."
      },
      "Required": true
    }
  },
  "Resources": {
    "PasswordTaskHostAccountAttachment": {
      "Type": "ALIYUN::BastionHost::PasswordTaskHostAccountAttachment",
      "Properties": {
        "TaskId": {
          "Ref": "TaskId"
        },
        "InstanceId": {
          "Ref": "InstanceId"
        },
        "HostAccountIds": {
          "Ref": "HostAccountIds"
        }
      }
    }
  }
}