第 2 步:创建 Systems Manager 云连接器
设置该云连接器后,创建 Systems Manager 云连接器。Systems Manager 云连接器存储 Azure 租户和订阅配置,并将其链接至连接器。
创建 Systems Manager 云连接器
-
运行如下命令。将占位符值替换为您的 Azure 租户 ID、Systems Manager 应用程序(客户端)ID、订阅 ID、Systems Manager Azure 联合身份验证角色 ARN 和步骤 1 中的连接器 ARN。
aws ssm create-cloud-connector \ --display-name "MyAzureConnector" \ --configuration '{ "AzureConfiguration": { "TenantId": "TENANT_ID", "ApplicationId": "SSM_APP_CLIENT_ID", "Targets": { "Subscriptions": [ {"Id": "SUBSCRIPTION_ID"} ] } } }' \ --role-arn "arn:aws:iam::ACCOUNT_ID:role/service-role/SSM-AzureRole-CONNECTOR_NAME-ID8" \ --config-connector-arnCONFIG_CONNECTOR_ARN要针对租户中的所有订阅(租户级设置),请省略配置中的
Targets字段。响应会返回
CloudConnectorId和CloudConnectorArn。请记下这些值以供未来操作使用。 -
验证云连接器是否创建成功:
aws ssm get-cloud-connector \ --cloud-connector-idCLOUD_CONNECTOR_ID