Todos los productos
Search
Centro de documentos

Resource Orchestration Service:ALIYUN::ENS::NetworkAclAssociation

Última actualización: Sep 04, 2026

Asocia una lista de control de acceso de red (ACL) con redes.

Sintaxis

{
  "Type": "ALIYUN::ENS::NetworkAclAssociation",
  "Properties": {
    "NetworkAclId": String,
    "NetworkIds": List
  }
}

Propiedades

Propiedad

Tipo

Obligatorio

Editable

Descripción

Restricción

NetworkAclId

String

Sí

No

El ID de la ACL.

Ninguna.

NetworkIds

List

Sí

No

Los ID de las redes que desea asociar con la ACL de red.

Especifique hasta 30 ID de red.

Valores de retorno

Fn::GetAtt

NetworkAclId: el ID de la ACL.

Ejemplos

Formato de YAML

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  NetworkAclId:
    Type: String
    Description:
      en: The ID of the network ACL.
    Required: true
  NetworkIds:
    AssociationPropertyMetadata:
      Parameter:
        Type: String
        Required: false
    AssociationProperty: List[Parameter]
    Type: Json
    Description:
      en: The network id which you want to associate the network ACL.
    Required: true
    MinLength: 1
    MaxLength: 30
Resources:
  NetworkAclAssociation:
    Type: ALIYUN::ENS::NetworkAclAssociation
    Properties:
      NetworkAclId:
        Ref: NetworkAclId
      NetworkIds:
        Ref: NetworkIds
Outputs:
  NetworkAclId:
    Description: The network acl id to associate.
    Value:
      Fn::GetAtt:
        - NetworkAclAssociation
        - NetworkAclId

Formato de JSON

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "NetworkAclId": {
      "Type": "String",
      "Description": {
        "en": "The ID of the network ACL."
      },
      "Required": true
    },
    "NetworkIds": {
      "AssociationPropertyMetadata": {
        "Parameter": {
          "Type": "String",
          "Required": false
        }
      },
      "AssociationProperty": "List[Parameter]",
      "Type": "Json",
      "Description": {
        "en": "The network id which you want to associate the network ACL."
      },
      "Required": true,
      "MinLength": 1,
      "MaxLength": 30
    }
  },
  "Resources": {
    "NetworkAclAssociation": {
      "Type": "ALIYUN::ENS::NetworkAclAssociation",
      "Properties": {
        "NetworkAclId": {
          "Ref": "NetworkAclId"
        },
        "NetworkIds": {
          "Ref": "NetworkIds"
        }
      }
    }
  },
  "Outputs": {
    "NetworkAclId": {
      "Description": "The network acl id to associate.",
      "Value": {
        "Fn::GetAtt": [
          "NetworkAclAssociation",
          "NetworkAclId"
        ]
      }
    }
  }
}