ALIYUN::ASM::ServiceMesh类型用于创建服务网格实例。
语法
{
"Type": "ALIYUN::ASM::ServiceMesh",
"Properties": {
"EnableAudit": Boolean,
"OPA": Map,
"IstioVersion": String,
"ApiServerPublicEip": Boolean,
"LocalityLoadBalancing": Boolean,
"Telemetry": Boolean,
"OutboundTrafficPolicy": String,
"AuditProject": String,
"TraceSampling": Number,
"Name": String,
"Proxy": Map,
"VpcId": String,
"PilotPublicEip": Boolean,
"IncludeIPRanges": String,
"VSwitches": List,
"Tracing": Boolean,
"CustomizedZipkin": Boolean,
"EnableACMG": Boolean,
"CustomizedPrometheus": Boolean,
"MSEEnabled": Boolean,
"WebAssemblyFilterEnabled": Boolean,
"CRAggregationEnabled": Boolean,
"CertChain": String,
"ConfigSourceNacosID": String,
"ConfigSourceEnabled": Boolean,
"EnableSDSServer": Boolean,
"DNSProxyingEnabled": Boolean,
"OpaEnabled": Boolean,
"LocalityLBConf": String,
"GuestCluster": String,
"KialiEnabled": Boolean,
"ControlPlaneLogEnabled": Boolean,
"EnableAmbient": Boolean,
"ExistingCaKey": String,
"ApiServerLoadBalancerSpec": String,
"ExcludeIPRanges": String,
"FilterGatewayClusterConfig": Boolean,
"PilotLoadBalancerSpec": String,
"AutoRenew": Boolean,
"AccessLogServiceEnabled": Boolean,
"ExistingRootCaCert": String,
"MysqlFilterEnabled": Boolean,
"GatewayAPIEnabled": Boolean,
"ControlPlaneLogProject": String,
"Edition": String,
"UseExistingCA": Boolean,
"ChargeType": String,
"ExistingCaType": String,
"PlaygroundScene": String,
"AccessLogEnabled": Boolean,
"AccessLogProject": String,
"ExistingRootCaKey": String,
"ExistingCaCert": String,
"Period": Number,
"ExcludeInboundPorts": String,
"ClusterSpec": String,
"MultiBufferPollDelay": String,
"AccessLogServicePort": Integer,
"ExcludeOutboundPorts": String,
"PrometheusUrl": String,
"AccessLogFormat": String,
"DubboFilterEnabled": Boolean,
"AutoRenewPeriod": Integer,
"AccessLogFile": String,
"MultiBufferEnabled": Boolean,
"EnableCRHistory": Boolean,
"AccessLogServiceHost": String
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
VpcId | String | 是 | 否 | 专有网络ID。 | 无 |
VSwitches | List | 是 | 否 | 交换机ID。 | 无 |
ApiServerPublicEip | Boolean | 否 | 否 | 是否使用公网地址暴露API Server。 | 取值:
|
AuditProject | String | 否 | 是 | 网格审计对应的日志项目名称。 | 默认值:mesh-log-{meshId}。 |
EnableACMG | Boolean | 否 | 否 | 是否启用 ACMG 模式。 | 无 |
CustomizedPrometheus | Boolean | 否 | 否 | 是否自定义 Prometheus。 | 取值:
默认值: |
MSEEnabled | Boolean | 否 | 否 | 是否启用 MSE 微服务引擎。 | 取值:
默认值: |
WebAssemblyFilterEnabled | Boolean | 否 | 否 | 是否启用 WebAssemblyFilter。 | 取值:
默认值: |
CRAggregationEnabled | Boolean | 否 | 否 | 是否启用数据面集群 Kubernetes API 访问 Istio 资源。 | 取值:
默认值: |
CertChain | String | 否 | 否 | 从 CaCert 到 RootCert 的证书链,至少包含两个证书。 | 无 |
ConfigSourceNacosID | String | 否 | 否 | Nacos 注册中心实例 ID。 | 无 |
ConfigSourceEnabled | Boolean | 否 | 否 | 是否启用外部服务注册中心。 | 取值:
默认值: |
EnableSDSServer | Boolean | 否 | 否 | 是否启用 SDS 服务。 | 取值:
默认值: |
DNSProxyingEnabled | Boolean | 否 | 否 | 是否启用 DNS 代理能力。 | 取值:
默认值: |
OpaEnabled | Boolean | 否 | 否 | 是否启用 OPA。 | 取值:
默认值: |
LocalityLBConf | String | 否 | 否 | 服务就近访问配置。 | 无 |
GuestCluster | String | 否 | 否 | 创建网格时可以选择一个集群加入网格,若为空时不会添加集群。 | 该集群需要和网格在同一个 VPC 的同一个 VSwitch 中,且集群域名相同。 |
KialiEnabled | Boolean | 否 | 否 | 是否启用网格拓扑。 | 取值:
默认值: |
ControlPlaneLogEnabled | Boolean | 否 | 否 | 是否启用控制面日志采集。 | 取值:
默认值: |
EnableAmbient | Boolean | 否 | 否 | 是否为服务网格实例启用 Ambient Mesh 模式。 | 无 |
ExistingCaKey | String | 否 | 否 | CA Key。 | 该参数一般用于自建 Istio 迁移 ASM 的场景下,对应自建 Istio 集群的 istio-system 命名空间下名称为 istio-ca-secret 的 secret 的 ca-key.pem 文件内容。 |
ApiServerLoadBalancerSpec | String | 否 | 否 | APIServer 绑定的 CLB 规格。 | 取值:简约型 I( |
ExcludeIPRanges | String | 否 | 否 | 排除拦截对外访问的地址范围。 | 无 |
FilterGatewayClusterConfig | Boolean | 否 | 否 | 是否启用 Gateway 配置过滤。 | 取值:
默认值: |
PilotLoadBalancerSpec | String | 否 | 否 | 服务网格控制面的 Istio Pilot 绑定的 CLB 规格。 | 取值:简约型 I( |
AutoRenew | Boolean | 否 | 否 | CLB 为包年包月类型时,是否自动续费。 | 取值:
|
AccessLogServiceEnabled | Boolean | 否 | 否 | 是否启用 Envoy 的 gRPC 日志服务(ALS)。 | 取值:
默认值: |
ExistingRootCaCert | String | 否 | 否 | 已有的根证书。 | 无 |
MysqlFilterEnabled | Boolean | 否 | 否 | 是否启用 MysqlFilter。 | 取值:
默认值: |
GatewayAPIEnabled | Boolean | 否 | 否 | 是否启用 Gateway API。 | 取值:
默认值: |
ControlPlaneLogProject | String | 否 | 否 | 控制面日志采集的 SLS Project。 | 无 |
Edition | String | 否 | 否 | ASM 实例版本。 | 无 |
UseExistingCA | Boolean | 否 | 否 | 使用已有的 CA 证书和私钥。 | 无 |
ChargeType | String | 否 | 否 | CLB 付费类型。 | 取值:
|
ExistingCaType | String | 否 | 否 | 已有的证书类型。 |
|
PlaygroundScene | String | 否 | 否 | Playground 场景。 | 可选值:
|
AccessLogEnabled | Boolean | 否 | 否 | 是否启用访问日志。 | 取值:
默认值: |
AccessLogProject | String | 否 | 否 | 访问日志采集的 SLS Project。 | 无 |
ExistingRootCaKey | String | 否 | 否 | 已有的根证书对应的私钥。 | 无 |
ExistingCaCert | String | 否 | 否 | CA 证书(Base64 Encode 格式)。 | 该参数一般用于自建 Istio 迁移 ASM 的场景下,对应自建 Istio 集群的 istio-system 命名空间下名称为 istio-ca-secret 的 secret 的 ca-cert.pem 文件内容。 |
Period | Number | 否 | 否 | 表示购买包年包月类型的 CLB 时,购买的月份。 |
|
ExcludeInboundPorts | String | 否 | 否 | 以半角英文逗号(,)分隔的入站端口列表。 | 无 |
ClusterSpec | String | 否 | 否 | 服务网格实例规格。 | 取值:
|
MultiBufferPollDelay | String | 否 | 否 | MultiBuffer 开启状态同步时间。 | 默认 |
AccessLogServicePort | Integer | 否 | 否 | 启用 Envoy 的 gRPC 日志服务(ALS)的端口。 | 无 |
ExcludeOutboundPorts | String | 否 | 否 | 以半角英文逗号(,)分隔的出站端口列表。 | 无 |
PrometheusUrl | String | 否 | 否 | 自定义 Prometheus 服务地址。 | 无 |
AccessLogFormat | String | 否 | 否 | 自定义访问日志的格式。 | 本项字符串为 JSON 格式,且 JSON 字符串中必须至少包含下述的键值:authority_for、bytes_received、bytes_sent、downstream_local_address、downstream_remote_address、duration、istio_policy_status、method、path、protocol、requested_server_name、response_code、response_flags、route_name、start_time、trace_id、upstream_cluster、upstream_host、upstream_local_address、upstream_service_time、upstream_transport_failure_reason、user_agent、x_forwarded_for。 示例:
|
DubboFilterEnabled | Boolean | 否 | 否 | 是否启用 DubboFilter。 | 取值:
默认值: |
AutoRenewPeriod | Integer | 否 | 否 | 表示购买包年包月类型的 CLB 时,自动续费的时间。 |
|
AccessLogFile | String | 否 | 否 | 开启和关闭访问日志。 | 取值:
|
MultiBufferEnabled | Boolean | 否 | 否 | 是否启用基于 MultiBuffer 的 TLS 性能优化。 | 取值:
默认值: |
EnableCRHistory | Boolean | 否 | 否 | 是否启用 ASM 的 Istio 资源历史版本管理功能。 | 取值:
默认值: |
AccessLogServiceHost | String | 否 | 否 | 启用 Envoy 的 gRPC 日志服务(ALS)的地址。 | 无 |
CustomizedZipkin | Boolean | 否 | 是 | 是否启用自建Zipkin。 | 取值:
|
EnableAudit | Boolean | 否 | 是 | 是否启用网格审计 。 | 取值:
说明 您需要开通阿里云日志服务。 |
IncludeIPRanges | String | 否 | 是 | 拦截对外访问的地址范围。 | 无 |
IstioVersion | String | 否 | 否 | Istio版本号。 | 无 |
LocalityLoadBalancing | Boolean | 否 | 是 | 是否启用服务就近访问。 | 取值:
|
Name | String | 否 | 否 | 服务网格名称。 | 无 |
OPA | Map | 否 | 是 | 开放策略代理。 | 更多信息,请参见OPA属性。 |
OutboundTrafficPolicy | String | 否 | 是 | 对外部服务的访问策略。 | 取值:
|
PilotPublicEip | Boolean | 否 | 否 | 是否使用公网地址暴露Istio Pilot。 | 取值:
|
Proxy | Map | 否 | 是 | 代理。 | 更多信息,请参见Proxy属性。 |
Telemetry | Boolean | 否 | 是 | 开启采集Prometheus监控指标。 | 建议您使用阿里云Prometheus监控。 |
TraceSampling | Number | 否 | 是 | 链路追踪采样百分比。 | 无 |
Tracing | Boolean | 否 | 是 | 是否启用链路追踪。 | 取值:
说明 您需要开通阿里云链路追踪服务。 |
OPA语法
"OPA": {
"OPARequestCPU": String,
"OpenAgentPolicy": Boolean,
"OPALogLevel": String,
"OPALimitCPU": String,
"OPALimitMemory": String,
"OPARequestMemory": String
}
OPA属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
OPALimitCPU | String | 否 | 是 | OPA代理容器的CPU资源限制。 | 无 |
OPALimitMemory | String | 否 | 是 | OPA代理容器的内存资源限制。 | 无 |
OPALogLevel | String | 否 | 是 | OPA代理容器日志级别。 | 无 |
OPARequestCPU | String | 否 | 是 | OPA代理容器的CPU资源请求。 | 无 |
OPARequestMemory | String | 否 | 是 | OPA代理容器的内存资源请求。 | 无 |
OpenAgentPolicy | Boolean | 否 | 是 | 是否集成开放策略代理(OPA)插件。 | 取值:
|
Proxy语法
"Proxy": {
"ClusterDomain": String,
"ProxyLimitCPU": String,
"ProxyLimitMemory": String,
"ProxyRequestCPU": String,
"ProxyRequestMemory": String
}
Proxy属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
ClusterDomain | String | 否 | 是 | 集群域名。 | 无 |
ProxyLimitCPU | String | 否 | 是 | CPU资源限制。 | 无 |
ProxyLimitMemory | String | 否 | 是 | 内存资源限制。 | 无 |
ProxyRequestCPU | String | 否 | 是 | CPU所需资源。 | 无 |
ProxyRequestMemory | String | 否 | 是 | 内存所需资源。 | 无 |
返回值
Fn::GetAtt
ServiceMeshId:服务网格ID。
示例
YAML
格式
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
ZoneId:
Type: String
Description: Create an Availability Zone for an instance to ensure that the Availability Zone supports the creation of Memcache resource specifications.
AssociationProperty: ALIYUN::ECS::Instance::ZoneId
Label: Zone ID
VPC:
AssociationProperty: ALIYUN::ECS::VPC::VPCId
Type: String
Description: Please search the ID starts with (vpc-xxx)from console-Virtual Private Cloud
Label: Existing VPC Instance ID
VSwitch:
AssociationProperty: ALIYUN::ECS::VSwitch::VSwitchId
Type: String
Description: Please search the business VSwitch ID starts with(vsw-xxx)from console-Virtual Private Cloud-VSwitches
Label: Existing VSwitch ID
AssociationPropertyMetadata:
VpcId: VPC
ZoneId: ZoneId
Resources:
ServiceMesh:
Type: ALIYUN::ASM::ServiceMesh
Properties:
VpcId:
Ref: VPC
VSwitches:
- Ref: VSwitch
Outputs:
ServiceMeshId:
Description: The ID of the ASM instance.
Value:
Fn::GetAtt:
- ServiceMesh
- ServiceMeshId
JSON
格式
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"ZoneId": {
"Type": "String",
"Description": "Create an Availability Zone for an instance to ensure that the Availability Zone supports the creation of Memcache resource specifications.",
"AssociationProperty": "ALIYUN::ECS::Instance::ZoneId",
"Label": "Zone ID"
},
"VPC": {
"AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
"Type": "String",
"Description": "Please search the ID starts with (vpc-xxx)from console-Virtual Private Cloud",
"Label": "Existing VPC Instance ID"
},
"VSwitch": {
"AssociationProperty": "ALIYUN::ECS::VSwitch::VSwitchId",
"Type": "String",
"Description": "Please search the business VSwitch ID starts with(vsw-xxx)from console-Virtual Private Cloud-VSwitches",
"Label": "Existing VSwitch ID",
"AssociationPropertyMetadata": {
"VpcId": "VPC",
"ZoneId": "ZoneId"
}
}
},
"Resources": {
"ServiceMesh": {
"Type": "ALIYUN::ASM::ServiceMesh",
"Properties": {
"VpcId": {
"Ref": "VPC"
},
"VSwitches": [
{
"Ref": "VSwitch"
}
]
}
}
},
"Outputs": {
"ServiceMeshId": {
"Description": "The ID of the ASM instance.",
"Value": {
"Fn::GetAtt": [
"ServiceMesh",
"ServiceMeshId"
]
}
}
}
}