Tous les produits
Search
Centre de documentation

CloudOps Orchestration Service:ACS-RDS-ReleaseInstancePublicConnection

Dernière mise à jour :Aug 11, 2026

Libère l'endpoint public d'une instance ApsaraDB RDS.

Nom du modèle

ACS-RDS-ReleaseInstancePublicConnection - Libère l'endpoint public d'une instance RDS

Exécuter maintenant

Description du modèle

Libère l'adresse IP publique d'une instance ApsaraDB RDS.

Type de modèle

Automatisé

Propriétaire

Alibaba Cloud

Paramètres d'entrée

Paramètre

Description

Type de données

Obligatoire

Valeur par défaut

Limite

instanceId

ID de l'instance ApsaraDB RDS.

String

Oui

regionId

ID de la région.

String

Non

{{ ACS::RegionId }}

OOSAssumeRole

Rôle RAM endossé par le service CloudOps Orchestration Service (OOS).

String

Non

""

Paramètres de sortie

N/A

Stratégie d'autorisations requise pour exécuter le modèle

{
    "Version": "1",
    "Statement": [
        {
            "Action": [
                "rds:DescribeDBInstanceNetInfo",
                "rds:ReleaseInstancePublicConnection"
            ],
            "Resource": "*",
            "Effect": "Allow"
        }
    ]
}

Détails

ACS-RDS-ReleaseInstancePublicConnection

Contenu du modèle

FormatVersion: OOS-2019-06-01
Description:
  en: Release the public endpoint of the RDS instance.
  zh-cn: Release the public endpoint of the RDS instance.
  name-en: ACS-RDS-ReleaseInstancePublicConnection
  name-zh-cn: Release the public endpoint of the RDS instance.
  categories:
    - security
    - rds
Parameters:
  regionId:
    Label:
      en: RegionId
      zh-cn: Region ID
    Type: String
    AssociationProperty: RegionId
    Default: '{{ ACS::RegionId }}'
  instanceId:
    Label:
      en: InstanceId
      zh-cn: RDS instance ID
    AssociationProperty: ALIYUN::RDS::Instance::InstanceId
    AssociationPropertyMetadata:
      RegionId: regionId
    Type: String
  OOSAssumeRole:
    Label:
      en: OOSAssumeRole
      zh-cn: The RAM role that OOS assumes.
    Type: String
    Default: ''
RamRole: '{{ OOSAssumeRole }}'
Tasks:
  - Name: describeDBInstanceNetInfo
    Action: 'ACS::ExecuteAPI'
    Description:
      en: Query the connection type and endpoint of an RDS instance.
      zh-cn: Query the connection endpoint and type of an RDS instance.
    Properties:
      Service: RDS
      API: DescribeDBInstanceNetInfo
      Parameters:
        RegionId: '{{ regionId }}'
        DBInstanceId: '{{ instanceId }}'
    Outputs:
      connectionString:
        Type: String
        ValueSelector: '.DBInstanceNetInfos.DBInstanceNetInfo[] | select(.IPType=="Public") | .ConnectionString'
  - Name: checkPublicAddress
    Action: 'ACS::Choice'
    Description:
      en: Check whether to release the public endpoint of the instance.
      zh-cn: Check whether to release the public endpoint of the RDS instance.
    Properties:
      DefaultTask: releaseInstancePublicConnection
      Choices:
        - When:
            'Fn::Equals':
              - Null
              - '{{ describeDBInstanceNetInfo.connectionString }}'
          NextTask: 'ACS::END'
  - Name: releaseInstancePublicConnection
    Action: 'ACS::ExecuteAPI'
    Description:
      en: Release the public endpoint of the RDS instance.
      zh-cn: Release the public endpoint of the RDS instance.
    Properties:
      Service: RDS
      API: ReleaseInstancePublicConnection
      Parameters:
        RegionId: '{{ regionId }}'
        DBInstanceId: '{{ instanceId }}'
        CurrentConnectionString: '{{ describeDBInstanceNetInfo.connectionString }}'
Metadata:
  ALIYUN::OOS::Interface:
    ParameterGroups:
      - Parameters:
          - regionId
          - instanceId
        Label:
          default:
            zh-cn: Select instance
            en: Select instance
      - Parameters:
          - OOSAssumeRole
        Label:
          default:
            zh-cn: Advanced options
            en: Advanced options