你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

LabelSelector interface

标签选择器是对一组资源的标签查询。 matchLabels 和 matchExpressions 的结果为 ANDed。 空标签选择器与所有对象匹配。 null 标签选择器与任何对象匹配。

属性

matchExpressions

matchExpressions 是标签选择器要求的列表。 要求是 ANDed。

matchLabels

matchLabels 是 {key,value} 对的映射。 matchLabels 映射中的单个 {key,value} 等效于 matchExpressions 的元素,其键字段为“key”,运算符为“In”,值数组仅包含“value”。 要求是 ANDed。

属性详细信息

matchExpressions

matchExpressions 是标签选择器要求的列表。 要求是 ANDed。

matchExpressions?: LabelSelectorRequirement[]

属性值

matchLabels

matchLabels 是 {key,value} 对的映射。 matchLabels 映射中的单个 {key,value} 等效于 matchExpressions 的元素,其键字段为“key”,运算符为“In”,值数组仅包含“value”。 要求是 ANDed。

matchLabels?: Record<string, string>

属性值

Record<string, string>